Video Coding Method and Apparatus Based on Inter Prediction
The method and apparatus for video coding using inter prediction improve video coding efficiency by obtaining specific flags, determining a regular merge flag, and performing inter prediction, effectively addressing the challenges of high-resolution and high-quality image/video compression.
Patent Information
- Application Number
- JP2024110782
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2019-06-19
- Filing Date
- 2024-07-10
- Publication Date
- 2025-05-27
- Estimated Expiration
- 2040-06-19
AI Technical Summary
There is a need for a highly efficient image/video compression technology to effectively compress, transmit, store, and reproduce high-resolution and high-quality images/videos with various characteristics, particularly to improve video coding efficiency, efficiently perform inter prediction, prevent unnecessary signaling, and efficiently signal merge data syntax.
A method and apparatus for coding video based on inter prediction, which includes obtaining flags such as CIIP available flag and CU skip flag from a bitstream, determining a regular merge flag based on certain conditions, and performing inter prediction to generate a predicted sample for a current block, thereby improving video coding efficiency and reducing unnecessary signaling.
The proposed solution enhances video coding efficiency, enables efficient inter prediction, minimizes unnecessary syntax signaling, and effectively signals merge data syntax, thereby addressing the challenges of high-resolution and high-quality image/video compression.
Smart Images

Figure 0007684487000044 
Figure 0007684487000045 
Figure 0007684487000046
Abstract
Description
Technical Field
[0001] The present technology relates to a method and apparatus for coding video based on inter prediction.
Background Art
[0002] In recent years, the demand for high-resolution and high-quality images / videos such as 4K or UHD (Ultra High Definition) images / videos of 8K or higher has been increasing in various fields. As the image / video data becomes higher in resolution and quality, the amount of information or bits to be transmitted relatively increases compared to the existing image / video data. Therefore, when transmitting image data using a medium such as an existing wired or wireless broadband line, or storing image / video data using an existing storage medium, the transmission cost and storage cost increase.
[0003] Also, in recent years, the interest and demand for immersive media such as VR (Virtual Reality), AR (Artificial Reality) content, and holograms have been increasing, and the broadcast of images / videos having image characteristics different from real images, such as game images, has been increasing.
[0004] Accordingly, there is a need for a highly efficient image / video compression technology to effectively compress, transmit, store, and reproduce information of high-resolution and high-quality images / videos having various characteristics as described above.
Summary of the Invention
Problems to be Solved by the Invention
[0005] The technical problem of this document is to provide a method and apparatus for increasing video coding efficiency.
[0006] Another technical problem of this document is to provide a method and apparatus for efficiently performing inter prediction.
[0007] Another technical problem of this document is to provide a method and an apparatus for preventing unnecessary signaling during inter prediction.
[0008] Another technical problem of this document is to provide a method and an apparatus for efficiently signaling merge data syntax.
Means for Solving the Problem
[0009] According to an embodiment of this document, a decoding method performed by a decoding apparatus includes: obtaining at least one of a combined inter-picture merge and intra-picture prediction (CIIP) available flag and a coding unit (CU) skip flag indicating whether a skip mode is applied to a current block from a bitstream; obtaining a regular merge flag from the bitstream based on satisfaction of at least one of a condition based on the CIIP available flag, a condition based on the CU skip flag, and a condition based on a size of the current block; performing an inter prediction based on the regular merge flag to generate a predicted sample of the current block; and generating a restored sample based on the predicted sample.
[0010] According to another embodiment of the present document, the encoding method performed by the encoding device includes steps of deriving a predicted sample of a current block based on inter prediction, generating information regarding a prediction mode indicating the prediction mode of the current block, deriving a residual sample based on the predicted sample, generating residual information based on the residual sample, and encoding video information including the information regarding the prediction mode and the residual information. However, the video information further includes at least one of a CIIP available flag and a CU skip flag indicating whether skip mode is applicable to the current block, and the video information includes a regular merge flag based on satisfaction of at least one of conditions based on the CIIP available flag and conditions based on the CU skip flag and conditions based on the size of the current block.
[0011] According to still another embodiment of the present document, a computer-readable digital storage medium includes information for causing a decoding device to perform a decoding method. The decoding method includes steps of obtaining at least one of a CIIP available flag and a CU skip flag indicating whether skip mode is applicable to the current block from a bitstream, obtaining a regular merge flag from the bitstream based on satisfaction of at least one of conditions based on the CIIP available flag and conditions based on the CU skip flag and conditions based on the size of the current block, performing inter prediction based on the regular merge flag to generate a predicted sample for the current block, and generating a restored picture based on the predicted sample.
Advantages of the Invention
[0012] According to one embodiment of the present document, general video / video compression efficiency can be improved.
[0013] According to an embodiment of this document, efficient inter prediction can be performed.
[0014] According to an embodiment of this document, unnecessary syntax signaling during inter prediction can be efficiently removed.
[0015] According to an embodiment of this document, merge data syntax can be efficiently signaled.
Brief Description of the Drawings
[0016]
Figure 1
Figure 2
Figure 3
Figure 4
Figure 5
Figure 6
Figure 7
Figure 8
Figure 9
Figure 10
Figure 11
Figure 12
Figure 13
Figure 14
Best Mode for Carrying Out the Invention
[0017] The disclosure of this document can be modified in various ways and can have various embodiments. Therefore, specific embodiments will be illustrated in the drawings and described in detail. The terms used in this document are merely used to describe specific embodiments and are not intended to limit the technical idea of this document. Singular expressions include the expression "at least one" unless the context clearly has a different meaning. Terms such as "including" or "having" in this document are intended to specify the presence of features, numbers, steps, operations, components, parts, or combinations thereof described in the specification, and it should be understood that the presence or possibility of addition of one or more other features, numbers, steps, operations, components, parts, or combinations thereof is not precluded in advance.
[0018] On the other hand, each configuration in the drawings described in this document is independently illustrated for the convenience of explaining different characteristic functions. It does not mean that each configuration is realized by separate hardware or separate software. For example, among the configurations, two or more configurations can be combined to form one configuration, and one configuration can also be divided into multiple configurations. Embodiments in which each configuration is integrated and / or separated are included in the disclosure scope of this document as long as they do not deviate from the essence of the method disclosed in this document.
[0019] In this document, the terms " / " and "," shall be construed to mean "and / or". For example, "A / B" shall be construed to mean "A and / or B", and "A, B" shall be construed to mean "A and / or B". Additionally, "A / B / C" means "at least one of A, B, and / or C". Also, "A, B, C" also means "at least one of A, B, and / or C".
[0020] Further, in this document, the term "or" shall be construed to mean "and / or". For example, "A or B" may mean: 1) only A, 2) only B, or 3) both A and B. In other words, the term "or" in this document may mean "additionally or alternatively".
[0021] This document relates to video / image coding. For example, the methods / embodiments disclosed in this document can be applied to the methods disclosed in the VVC (Versatile Video Coding) standard. Also, the methods / embodiments disclosed in this document can be applied to the methods disclosed in the EVC (Essential Video Coding) standard, AV1 (AOMedia Video 1) standard, AVS2 (2nd generation of Audio Video Coding Standard) or next-generation video / image coding standards (e.g., H.267, H.268, etc.).
[0022] In this document, various embodiments related to video / image coding are presented, and unless otherwise specified, the embodiments can be combined with each other.
[0023] Hereinafter, with reference to the accompanying drawings, the embodiments of this document will be described in more detail. Hereinafter, the same reference numerals will be used for the same components in the drawings, and redundant descriptions regarding the same components will be omitted.
[0024] FIG. 1 schematically shows an example of a video / image coding system to which the embodiments of this document can be applied.
[0025] As shown in FIG. 1, the video / image coding system includes a first device (source device) and a second device (receiver device). The source device can transmit encoded video / image information or data to the receiver device via a digital storage medium or a network in file or streaming form.
[0026] The source device can include a video source, an encoding device, and a transmitting unit. The receiving device can include a receiving unit, a decoding device, and a renderer. The encoding device can be called a video / video encoding device, and the decoding device can be called a video / video decoding device. A transmitter can be included in the encoding device. A receiver can be included in the decoding device. The renderer can also include a display unit, and the display unit can also be composed of a separate device or an external component.
[0027] The video source can obtain video / video through processes such as video / video capture, synthesis, or generation. The video source can include a video / video capture device and / or a video / video generation device. The video / video capture device can include, for example, one or more cameras, a video / video archive containing previously captured video / video, etc. The video / video generation device can include, for example, a computer, a tablet, and a smartphone, etc., and can (electronically) generate video / video. For example, virtual video / video can be generated through a computer or the like, and in this case, the video / video capture process can be replaced by a process in which related data is generated.
[0028] The encoding device can encode the input video / video. The encoding device can execute a series of procedures such as prediction, conversion, quantization, etc. for compression and coding efficiency. The encoded data (encoded video / video information) can be output in the form of a bitstream.
[0029] The transmitting unit can transmit the encoded video / video information or data output in bitstream form to the receiving unit of the receiving device via a digital storage medium or network in file or streaming form. The digital storage medium can include various storage media such as USB, SD, CD, DVD, Blu-ray, HDD, SSD, etc. The transmitting unit can include elements for generating a media file via a predetermined file format and can include elements for transmission via a broadcast / communication network. The receiving unit can receive / extract the bitstream and transmit it to the decoding device.
[0030] The decoding device can decode the video / video by performing a series of procedures such as inverse quantization, inverse transformation, prediction, etc. corresponding to the operation of the encoding device.
[0031] The renderer can render the decoded video / video. The rendered video / video can be displayed via the display unit.
[0032] In this document, at least one of quantization / inverse quantization and / or transformation / inverse transformation may be omitted. When the quantization / inverse quantization is omitted, the quantized transform coefficient may be called a transform coefficient. When the transformation / inverse transformation is omitted, the transform coefficient may be called a coefficient or a residual coefficient, or may be called a transform coefficient for the sake of uniformity of expression.
[0033] In this document, the quantized transform coefficient and the transform coefficient may be referred to as the transform coefficient and the scaled transform coefficient, respectively. In this case, the residual information includes information about the transform coefficient(s), and the information about the transform coefficient(s) can be signaled via a residual coding syntax. The transform coefficient is derived based on the residual information (or the information about the transform coefficient(s)), and the scaled transform coefficient can be derived by an inverse transform (scaling) for the transform coefficient. The residual sample can be derived based on an inverse transform (transformation) for the scaled transform coefficient. This can be applied / expressed similarly in other parts of this document.
[0034] In this document, "video" may mean a collection of a series of images over time. "Picture" generally means a unit representing one image in a specific time period, and "slice" / "tile" is a unit that constitutes a part of a picture in coding. A slice / tile contains one or more CTUs (Coding Tree Units). One picture is composed of one or more slices / tiles. One picture is composed of one or more tile groups. One tile group contains one or more tiles. A brick represents a rectangular region of CTU rows within a tile in a picture. A tile may be partitioned into multiple bricks, each of which consisting of one or more CTU rows within the tile. A tile that is not partitioned into multiple bricks may be also referred to as a brick.A brick scan shows a specific sequential ordering of CTUs partitioning a picture in which the CTUs are ordered consecutively in CTU raster scan in a brick, bricks within a tile are ordered consecutively in a raster scan of the bricks of the tile, and tiles in a picture are ordered consecutively in a raster scan of the tiles of the picture. A tile is a rectangular region of CTUs within a particular tile column and a particular tile row in a picture. The tile column is a rectangular region of CTUs having a height equal to the height of the picture and a width specified by syntax elements in the picture parameter set.The tile row is a rectangular region of CTUs having a width specified by syntax elements in the picture parameter set and a height equal to the height of the picture. A tile scan is a specific sequential ordering of CTUs partitioning a picture in which the CTUs are ordered consecutively in CTU raster scan in a tile whereas tiles in a picture are ordered consecutively in a raster scan of the tiles of the picture. A slice includes an integer number of bricks of a picture that may be exclusively contained in a single NAL unit. A slice may consists of either a number of complete tiles or only a consecutive sequence of complete bricks of one tile. In this document, tile groups and slices may be used interchangeably.For example, in this document, a tile group / tile group header may be referred to as a slice / slice header.
[0035] A pixel or pel can mean the smallest unit that makes up one picture (or video). Also, the term "sample" can be used as a term corresponding to a pixel. A sample can generally indicate a pixel or a pixel value, and can also indicate only the pixel / pixel value of the luma component, or only the pixel / pixel value of the chroma component. Or, a sample can also mean a pixel value in the spatial domain, and when such a pixel value is converted to the frequency domain, it can also mean a conversion coefficient in the frequency domain.
[0036] A unit can indicate the basic unit of video processing. A unit can include at least one of a specific region of a picture and information related to the region. One unit can include one luma block and two chroma (e.g., cb, cr) blocks. A unit can, in some cases, be used interchangeably with terms such as block or area. In general, an M×N block can include a set (or array) of samples (or sample array) consisting of M columns and N rows, or a set (or array) of transform coefficients.
[0037] FIG. 2 is a diagram schematically explaining the configuration of a video / video encoding device to which the embodiments of this document can be applied. Hereinafter, a video encoding device includes a video encoding device.
[0038] As shown in FIG. 2, the encoding apparatus 200 can be configured to include an image partitioner 210, a predictor 220, a residual processor 230, an entropy encoder 240, an adder 250, a filter 260, and a memory 270. The predictor 220 can include an inter-predictor 221 and an intra-predictor 222. The residual processor 230 can include a transformer 232, a quantizer 233, a dequantizer 234, and an inverse transformer 235. The residual processor 230 can further include a subtractor 231. The adder 250 can be called a reconstructor or a reconstructed block generator. The aforementioned image partitioner 210, predictor 220, residual processor 230, entropy encoder 240, adder 250, and filter 260 can be configured by one or more hardware components (e.g., an encoder chipset or a processor) according to an embodiment. Also, the memory 270 can include a DPB (decoded picture buffer) and can also be configured by a digital storage medium. The hardware component can further include the memory 270 as an internal / external component.
[0039] The image segmentation unit 210 can divide an input image (or picture, frame) input to the encoding device 200 into one or more processing units. As an example, the processing unit can be called a coding unit (CU). In this case, the coding unit can be recursively divided from a coding tree unit (CTU) or a largest coding unit (LCU) by a QTBTTT (Quad-tree binary-tree ternary-tree) structure. For example, one coding unit can be divided into a plurality of coding units with a deeper depth based on a quad-tree structure, a binary-tree structure, and / or a ternary structure. In this case, for example, the quad-tree structure can be applied first, and the binary-tree structure and / or the ternary structure can be applied thereafter. Or, the binary-tree structure can also be applied first. The coding procedure according to the present disclosure can be performed based on the final coding unit that is no longer divided. In this case, based on the coding efficiency according to the image characteristics, etc., the largest coding unit can be used as the final coding unit, or, if necessary, the coding unit can be recursively divided into coding units with a deeper depth so that the coding unit with the optimal size can be used as the final coding unit. Here, the coding procedure can include procedures such as prediction, transformation, and restoration described later. As another example, the processing unit can further include a prediction unit (PU: Prediction Unit) or a transform unit (TU: Transform Unit). In this case, the prediction unit and the transform unit can be divided or partitioned from the final coding unit described above, respectively.The prediction unit can be a unit of sample prediction, and the conversion unit can be a unit for deriving a conversion coefficient and / or a unit for deriving a residual signal from the conversion coefficient.
[0040] The term "unit" can, in some cases, be used interchangeably with terms such as "block" or "area". In general, an M×N block can represent a set of samples or transform coefficients consisting of M columns and N rows. A sample can generally represent a pixel or a pixel value, and can represent only the pixel / pixel value of the luma component, or only the pixel / pixel value of the chroma component. A sample can be used as a term corresponding to a pixel or a pel in one picture (or image).
[0041] The encoding device 200 subtracts the prediction signal (predicted block, predicted sample array) output from the inter prediction unit 221 or the intra prediction unit 222 from the input video signal (original block, original sample array) to generate a residual signal (residual signal, residual block, residual sample array), and the generated residual signal is transmitted to the conversion unit 232. In this case, as shown in the figure, the unit that subtracts the prediction signal (predicted block, predicted sample array) from the input video signal (original block, original sample array) within the encoder 200 is called the subtraction unit 231. The prediction unit 220 can perform prediction on the block to be processed (hereinafter referred to as the current block) and generate a predicted block including predicted samples for the current block. The prediction unit 220 determines whether intra prediction or inter prediction is applied in units of the current block or CU. The prediction unit 220 can generate various information related to prediction, such as prediction mode information, as described later in the description of each prediction mode, and transmit it to the entropy encoding unit 240. The information related to prediction can be encoded in the entropy encoding unit 240 and output in the form of a bitstream.
[0042] The intra prediction unit 222 can predict the current block by referring to samples within the current picture. The samples to be referred to can be located adjacent to the current block according to the prediction mode, or can also be located remotely. In intra prediction, the prediction mode can include a plurality of non-directional modes and a plurality of directional modes. The non-directional modes can include, for example, the DC mode and the Planar mode. The directional modes can include, for example, 33 directional prediction modes or 65 directional prediction modes according to the degree of fineness of the prediction direction. However, this is an example, and more or fewer directional prediction modes can be used depending on the setting. The intra prediction unit 222 can also determine the prediction mode to be applied to the current block by using the prediction mode applied to the adjacent block.
[0043] The inter prediction unit 221 can derive a predicted block for the current block based on a reference block (reference sample array) specified by a motion vector on a reference picture. At this time, in order to reduce the amount of motion information transmitted in the inter prediction mode, the motion information can be predicted in units of blocks, sub-blocks, or samples based on the correlation of the motion information between adjacent blocks and the current block. The motion information can include a motion vector and a reference picture index. The motion information can further include inter prediction direction (L0 prediction, L1 prediction, Bi prediction, etc.) information. In the case of inter prediction, the adjacent blocks can include spatial neighboring blocks existing in the current picture and temporal neighboring blocks existing in the reference picture. The reference picture including the reference block and the reference picture including the temporal neighboring block can be the same or different. The temporal neighboring blocks can be called by names such as collocated reference blocks and collocated CUs (col CUs), and the reference picture including the temporal neighboring blocks can also be called a collocated picture (colPic). For example, the inter prediction unit 221 can construct a motion information candidate list based on adjacent blocks, and generate information indicating which candidate is used to derive the motion vector and / or reference picture index of the current block. Inter prediction can be performed based on various prediction modes. For example, in the case of skip mode and merge mode, the inter prediction unit 221 can use the motion information of adjacent blocks as the motion information of the current block. In the case of skip mode, unlike merge mode, a residual signal may not be transmitted.In the case of the motion information prediction (motion vector prediction, MVP) mode, the motion vector of an adjacent block is used as a motion vector predictor, and by signaling the motion vector difference, the motion vector of the current block can be indicated.
[0044] The prediction unit 220 generates a prediction signal based on various prediction methods described below. For example, the prediction unit 220 can apply intra prediction or inter prediction for the prediction of one block, and can also apply intra prediction and inter prediction simultaneously. This is called combined inter and intra prediction (CIIP). In addition, the prediction unit may be based on the intra block copy (IBC) prediction mode or the palette mode for the prediction of a block. The IBC prediction mode or the palette mode can be used, for example, for content video / movie coding such as games like SCC (screen content coding). IBC basically performs prediction within the current picture, but is performed similarly to inter prediction in terms of deriving a reference block within the current picture. That is, IBC can utilize at least one of the inter prediction techniques described in this document. The palette mode can be regarded as an example of intra coding or intra prediction. When the palette mode is applied, the sample values in the picture can be signaled based on information regarding the palette table and the palette index.
[0045] The prediction signal generated through the prediction unit (including the inter prediction unit 221 and / or the intra prediction unit 222) can be used to generate a restored signal or can be used to generate a residual signal.
[0046] The conversion unit 232 can generate transform coefficients by applying a conversion technique to the residual signal. For example, the conversion technique includes at least one of DCT (Discrete Cosine Transform), DST (Discrete Sine Transform), GBT (Graph-Based Transform), or CNT (Conditionally Non-linear Transform). Here, GBT means the conversion obtained from this graph when expressing the relationship information between pixels in a graph. CNT means the conversion obtained based on generating a prediction signal using all previously reconstructed pixels. Also, the conversion process may be applied to a pixel block having the same size of a square, or may be applied to a block of variable size that is not square.
[0047] The quantization unit 233 quantizes the transform coefficients and transmits them to the entropy encoding unit 240, and the entropy encoding unit 240 encodes the quantized signal (information regarding the quantized transform coefficients) and outputs it as a bit stream. The information regarding the quantized transform coefficients may be called residual information. The quantization unit 233 can also reorder the quantized transform coefficients in block form into a one-dimensional vector form based on the coefficient scan order, and generate the information regarding the quantized transform coefficients based on the quantized transform coefficients in the one-dimensional vector form.
[0048] The entropy encoding unit 240 can perform various encoding methods such as, for example, exponential Golomb, CAVLC (context-adaptive variable length coding), CABAC (context-adaptive binary arithmetic coding). In addition to the quantized transform coefficients, the entropy encoding unit 240 can also encode, together or separately, information necessary for video / image restoration (such as the values of syntax elements). The encoded information (such as the encoded video / video information) can be transmitted or stored in the form of a bitstream in units of NAL (network abstraction layer) units. The video / video information further includes information regarding various parameter sets such as an adaptation parameter set (APS), a picture parameter set (PPS), a sequence parameter set (SPS), or a video parameter set (VPS). Also, the video / video information may further include general constraint information. In this document, the information and / or syntax elements transmitted / signaled from the encoding device to the decoding device are included in the video / video information. The video / video information is encoded through the aforementioned encoding procedure and included in the bitstream. The bitstream may be transmitted via a network or stored in a digital storage medium. Here, the network includes a broadcast network and / or a communication network, etc., and the digital storage medium includes various storage media such as USB, SD, CD, DVD, Blu-ray, HDD, SSD, etc. A transmission unit (not shown) for transmitting and / or a storage unit (not shown) for storing the signal output from the entropy encoding unit 240 may be configured as internal / external elements of the encoding device 200, or the transmission unit may be included in the entropy encoding unit 240.
[0049] The quantized transform coefficients output from the quantization unit 233 can be used to generate a prediction signal. For example, by applying inverse quantization and inverse transformation to the quantized transform coefficients via the inverse quantization unit 234 and the inverse transformation unit 235, a residual signal (residual block or residual sample) is restored. The addition unit 250 adds the restored residual signal to the prediction signal output from the inter prediction unit 221 or the intra prediction unit 222, thereby generating a reconstructed signal (reconstructed picture, reconstructed block, reconstructed sample array). When there is no residual for the block to be processed, as in the case where the skip mode is applied, the predicted block can be used as the reconstructed block. The addition unit 250 may be referred to as a restoration unit or a reconstructed block generation unit. The generated reconstructed signal is used for intra prediction of the next block to be processed within the current picture, and as will be described later, it can also be used for inter prediction of the next picture after passing through filtering.
[0050] On the other hand, LMCS (luma mapping with chroma scaling) can also be applied in the picture encoding and / or restoration process.
[0051] The filtering unit 260 can apply filtering to the restored signal to improve the subjective / objective image quality. For example, the filtering unit 260 applies various filtering methods to the restored picture to generate a modified restored picture, and stores the modified restored picture in the memory 270, specifically, in the DPB of the memory 270. The various filtering methods include, for example, deblocking filtering, sample adaptive offset, adaptive loop filter, bilateral filter, etc. The filtering unit 260 generates various information related to filtering and transmits it to the entropy encoding unit 240, as will be described later in the description of each filtering method. The information related to filtering is encoded in the entropy encoding unit 240 and output in the form of a bit stream.
[0052] The modified restored picture transmitted to the memory 270 can be used as a reference picture in the inter prediction unit 221. The encoding device can thereby avoid prediction mismatches between the encoding device 100 and the decoding device when inter prediction is applied, and can also improve the encoding efficiency.
[0053] The DPB of the memory 270 can store the modified restored picture for use as a reference picture in the inter prediction unit 221. The memory 270 can store the motion information of the blocks for which the motion information in the current picture has been derived (or encoded) and / or the motion information of the blocks in the already restored picture. The stored motion information can be transmitted to the inter prediction unit 221 for utilization as the motion information of spatially adjacent blocks or temporally adjacent blocks. The memory 270 can store the restored samples of the restored blocks in the current picture and transmit them to the intra prediction unit 222.
[0054] FIG. 3 is a diagram schematically illustrating the configuration of a video / video decoding apparatus to which the embodiments of the present document can be applied.
[0055] As shown in FIG. 3, the decoding apparatus 300 can be configured to include an entropy decoder 310, a residual processor 320, a predictor 330, an adder 340, a filter 350, and a memory 360. The predictor 330 can include an inter-predictor 331 and an intra-predictor 332. The residual processor 320 can include a dequantizer 321 and an inverse transformer 321. The entropy decoder 310, the residual processor 320, the predictor 330, the adder 340, and the filter 350 described above can be configured by one hardware component (e.g., a decoder chipset or a processor) according to an embodiment. Also, the memory 360 can include a DPB (decoded picture buffer) and can also be configured by a digital storage medium. The hardware component can further include the memory 360 as an internal / external component.
[0056] If a bitstream including video / image information is input, the decoding device 300 can restore an image corresponding to the process in which the video / image information was processed by the encoding device in FIG. 3. For example, the decoding device 300 can derive units / blocks based on block division related information obtained from the bitstream. The decoding device 300 can perform decoding using the processing units applied in the encoding device. Therefore, the processing unit for decoding can be, for example, a coding unit, and the coding unit can be divided according to a quad tree structure, a binary tree structure, and / or a ternary tree structure from a coding tree unit or a maximum coding unit. One or more conversion units can be derived from the coding unit. Then, the restored image signal decoded and output via the decoding device 300 can be reproduced via a reproducing device.
[0057] The decoding device 300 receives the signal output from the encoding device in FIG. 2 in the form of a bitstream, and the received signal is decoded by the entropy decoding unit 310. For example, the entropy decoding unit 310 can parse the bitstream to derive information (such as video / video information) necessary for video restoration (or picture restoration). The video / video information may further include information regarding various parameter sets such as an adaptation parameter set (APS), a picture parameter set (PPS), a sequence parameter set (SPS), or a video parameter set (VPS). Also, the video / video information may further include general constraint information. The decoding device can further decode a picture based on the information regarding the parameter set and / or the general constraint information. The signaling / received information and / or syntax elements described later in this document can be decoded through the decoding procedure and obtained from the bitstream. For example, the entropy decoding unit 310 decodes the information in the bitstream based on a coding method such as exponential Golomb coding, CAVLC (context-adaptive variable length coding), or CABAC (context-adaptive arithmetic coding), and outputs the value of the syntax element necessary for video restoration and the quantized value of the transform coefficient regarding the residual. More specifically, the CABAC entropy decoding method receives the bin corresponding to each syntax element in the bitstream, determines a context model using the syntax element information to be decoded, the surrounding and decoding information of the decoding target block, or the information of the symbol / bin decoded in the previous step, predicts the occurrence probability of the bin according to the determined context model, and executes arithmetic decoding of the bin to generate a symbol corresponding to the value of each syntax element.At this time, the CABAC entropy decoding method can update the context model by using the information of the decoded symbol / bin for the context model of the next symbol / bin after determining the context model. Among the information decoded in the entropy decoding unit 310, the information related to prediction is provided to the prediction unit (inter prediction unit 332 and intra prediction unit 331), and the residual value obtained by performing entropy decoding in the entropy decoding unit 310, that is, the quantized transform coefficient and related parameter information can be input to the residual processing unit 320.
[0058] The residual processing unit 320 can derive a residual signal (residual block, residual sample, residual sample array). Also, among the information decoded in the entropy decoding unit 310, the information related to filtering is provided to the filtering unit 350. On the other hand, a receiving unit (not shown) that receives the signal output from the encoding device may be further configured as an internal / external element of the decoding device 300, and the receiving unit may be a component of the entropy decoding unit 310. On the other hand, the decoding device according to this document may be called a video / video / picture decoding device, and the decoding device can also be classified into an information decoder (video / video / picture information decoder) and a sample decoder (video / video / picture sample decoder). The information decoder includes the entropy decoding unit 310, and the sample decoder includes at least one of the inverse quantization unit 321, inverse transform unit 322, addition unit 340, filtering unit 350, memory 360, inter prediction unit 332, and intra prediction unit 331.
[0059] In the inverse quantization unit 321, the quantized transform coefficients can be inverse quantized to output the transform coefficients. The inverse quantization unit 321 can reorder the quantized transform coefficients in a two-dimensional block form. In this case, the reordering can be performed based on the coefficient scan order performed in the encoding device. The inverse quantization unit 321 can perform inverse quantization on the quantized transform coefficients using quantization parameters (e.g., quantization step size information) to obtain the transform coefficients.
[0060] In the inverse transform unit 322, the transform coefficients are inverse transformed to obtain a residual signal (residual block, residual sample array).
[0061] The prediction unit 330 performs prediction on the current block and generates a predicted block including the predicted samples for the current block. The prediction unit 330 can determine whether intra prediction or inter prediction is applied to the current block based on the information regarding the prediction output from the entropy decoding unit 310, and can determine a specific intra / inter prediction mode.
[0062] The prediction unit 330 can generate a prediction signal based on various prediction methods described later. For example, the prediction unit can apply not only intra prediction or inter prediction for the prediction of one block, but also apply intra prediction and inter prediction simultaneously. This may be called combined inter and intra prediction (CIIP). Also, the prediction unit may be based on the intra block copy (IBC) prediction mode or the palette mode for the prediction of the block. The IBC prediction mode or the palette mode can be used for content video / moving image coding such as games, for example, like SCC (screen content coding). IBC basically performs prediction within the current picture, but can be performed similarly to inter prediction in terms of deriving a reference block within the current picture. That is, IBC can utilize at least one of the inter prediction techniques described in this document. The palette mode can be regarded as an example of intra coding or intra prediction. When the palette mode is applied, information regarding the palette table and the palette index is included in and signaled in the video / video information.
[0063] The intra prediction unit 331 can predict the current block by referring to samples within the current picture. The samples to be referred to may be located around (neighbour) the current block or may be located far away depending on the prediction mode. In intra prediction, the prediction mode includes a plurality of non-directional modes and a plurality of directional modes. The intra prediction unit 331 can also determine the prediction mode to be applied to the current block using the prediction mode applied to the surrounding blocks.
[0064] The inter prediction unit 332 can derive a predicted block for the current block based on a reference block (reference sample array) specified by a motion vector on a reference picture. At that time, in order to reduce the amount of motion information transmitted in the inter prediction mode, the motion information can be predicted in units of blocks, sub-blocks, or samples based on the correlation of the motion information between the neighboring blocks and the current block. The motion information includes a motion vector and a reference picture index. The motion information may further include inter prediction direction (L0 prediction, L1 prediction, Bi prediction, etc.) information. In the case of inter prediction, the neighboring blocks include spatial neighboring blocks existing in the current picture and temporal neighboring blocks existing in the reference picture. For example, the inter prediction unit 332 can construct a motion information candidate list based on the neighboring blocks and derive the motion vector and / or reference picture index of the current block based on the received candidate selection information. Inter prediction can be performed based on various prediction modes, and the information regarding the prediction includes information indicating the inter prediction mode for the current block.
[0065] The addition unit 340 can generate a restored signal (restored picture, restored block, restored sample array) by adding the obtained residual signal to a predicted signal (predicted block, predicted sample array) output from a prediction unit (including the inter prediction unit 332 and / or the intra prediction unit 331). When there is no residual for the processing target block as in the case where the skip mode is applied, the predicted block can be used as the restored block.
[0066] The addition unit 340 can be called a restoration unit or a restored block generation unit. The generated restored signal can be used for intra prediction of the next processing target block in the current picture, can also be output after filtering as described later, or can be used for inter prediction of the next picture.
[0067] On the other hand, LMCS (luma mapping with chroma scaling) can also be applied in the picture decoding process.
[0068] The filtering unit 350 can apply filtering to the restored signal to improve subjective / objective image quality. For example, the filtering unit 350 can apply various filtering methods to the restored picture to generate a modified restored picture, and the modified restored picture can be sent to the memory 60, specifically, the DPB of the memory 360. The various filtering methods can include, for example, deblocking filtering, sample adaptive offset, adaptive loop filter, bilateral filter, and the like.
[0069] The (modified) restored picture stored in the DPB of the memory 360 can be used as a reference picture in the inter prediction unit 332. The memory 360 can store the motion information of the block where the motion information in the current picture has been derived (or decoded) and / or the motion information of the block in the already restored picture. The stored motion information is transmitted to the inter prediction unit 221 for utilization as the motion information of the spatial neighboring blocks or the motion information of the temporal neighboring blocks. The memory 360 can store the restored samples of the restored blocks in the current picture and can be transmitted to the intra prediction unit 331.
[0070] In this specification, the embodiments described in the filtering unit 260, the inter prediction unit 221, and the intra prediction unit 222 of the encoding device 200 can be applied to the filtering unit 350, the inter prediction unit 332, and the intra prediction unit 331 of the decoding device 300 in the same or corresponding manner, respectively.
[0071] On one hand, as described above, prediction is performed to increase the compression efficiency when executing video coding. By doing so, a predicted block including prediction samples for a current block which is a block to be coded can be generated. Here, the predicted block includes prediction samples in the spatial domain (or pixel domain). The predicted block is derived in the same way in both the encoding device and the decoding device. The encoding device can improve the image coding efficiency by signaling information (residual information) regarding the residual between the original block and the predicted block, which is not the original sample value of the original block, to the decoding device. The decoding device can derive a residual block including residual samples based on the residual information, and can generate a restored block including restored samples by adding the residual block and the predicted block, and can generate a restored picture including the restored block.
[0072] The residual information can be generated through conversion and quantization procedures. For example, an encoding device can derive a residual block between the original block and the predicted block, execute a conversion procedure on the residual samples (residual sample array) included in the residual block to derive conversion coefficients, and execute a quantization procedure on the conversion coefficients to derive quantized conversion coefficients, thereby signaling the relevant residual information (via a bitstream) to a decoding device. Here, the residual information can include information such as the value information, position information, conversion technique, conversion kernel, quantization parameter, etc. of the quantized conversion coefficients. The decoding device can execute an inverse quantization / inverse conversion procedure based on the residual information to derive residual samples (or a residual block). The decoding device can generate a restored picture based on the predicted block and the residual block. Also, the encoding device can inverse quantize / inverse convert the quantized conversion coefficients for reference in inter prediction of subsequent pictures to derive a residual block, and generate a restored picture based on this.
[0073] When inter prediction is applied to a current block, the prediction unit of the encoding / decoding apparatus can perform inter prediction on a block-by-block basis to derive a prediction sample. Inter prediction indicates a prediction derived in a manner that is dependent on data elements (e.g., sample values or motion information) of picture(s) other than the current picture (Inter prediction can be a prediction derived in a manner that is dependent on data elements (e.g., sample values or motion information) of picture(s) other than the current picture). When inter prediction is applied to a current block, a predicted block (prediction sample array) for the current block can be derived based on a reference block (reference sample array) specified by a motion vector on a reference picture indicated by a reference picture index. At this time, in order to reduce the amount of motion information transmitted in the inter prediction mode, the motion information of the current block can be predicted in units of blocks, sub-blocks, or samples based on the correlation of the motion information between the neighboring blocks and the current block. The motion information includes a motion vector and a reference picture index. The motion information may further include information on an inter prediction type (L0 prediction, L1 prediction, Bi prediction, etc.). When inter prediction is applied, the neighboring blocks include spatial neighboring blocks existing within the current picture and temporal neighboring blocks existing in the reference picture. The reference picture including the reference block and the reference picture including the temporal neighboring block may be the same or different. The temporal neighboring block may be referred to by names such as a collocated reference block, a collocated CU (colCU), etc., and the reference picture including the temporal neighboring block may be referred to as a collocated picture (colPic).For example, a motion information candidate list is configured based on blocks around the current block, and flag or index information indicating which candidate is selected (used) to derive the motion vector and / or reference picture index of the current block can be signaled. Inter prediction can be performed based on various prediction modes. For example, in the case of skip mode and (normal) merge mode, the motion information of the current block may be the same as the motion information of the selected surrounding block. In the case of skip mode, unlike merge mode, a residual signal may not be transmitted. In the case of motion vector prediction (MVP) mode, the motion vector of the selected surrounding block is used as a motion vector predictor, and the motion vector difference can be signaled. In this case, the motion vector of the current block can be derived by using the sum of the motion vector predictor and the motion vector difference.
[0074] Video / video encoding procedures based on inter prediction generally include, for example, the following.
[0075] FIG. 4 shows an example of an inter prediction-based video / video encoding method.
[0076] The encoding device performs inter prediction on the current block (S400). The encoding device derives the inter prediction mode and motion information of the current block, and generates a prediction sample of the current block. Here, the inter prediction mode determination, motion information derivation, and prediction sample generation procedures may be performed simultaneously, or one procedure may be performed before the other procedures. For example, the inter prediction unit of the encoding device includes a prediction mode determination unit, a motion information derivation unit, and a prediction sample derivation unit. The prediction mode determination unit determines the prediction mode for the current block, the motion information derivation unit derives the motion information of the current block, and the prediction sample derivation unit derives the prediction sample of the current block. For example, the inter prediction unit of the encoding device can search for a block similar to the current block within a certain area (search area) of the reference picture by motion estimation, and derive a reference block whose difference from the current block is the smallest or below a certain criterion. Based on this, a reference picture index indicating the reference picture where the reference block is located is derived, and a motion vector is derived based on the positional difference between the reference block and the current block. The encoding device can determine the mode applied to the current block among various prediction modes. The encoding device can compare the RD (rate-distortion) costs for the various prediction modes and determine the optimal prediction mode for the current block.
[0077] For example, when the skip mode or the merge mode is applied to the current block, the encoding device constructs a merge candidate list described below, and can derive a reference block whose difference from the current block is the smallest or equal to or less than a certain criterion among the reference blocks pointed to by the merge candidates included in the merge candidate list. In this case, a merge candidate related to the derived reference block is selected, and merge index information indicating the selected merge candidate is generated and signaled to the decoding device. The motion information of the current block can be derived using the motion information of the selected merge candidate.
[0078] As another example, when the (A)MVP mode is applied to the current block, the encoding device constructs an (A)MVP candidate list described below, and the motion vector of the selected mvp (motion vector predictor) candidate among the mvp candidates included in the (A)MVP candidate list can be used as the mvp of the current block. In this case, for example, the motion vector pointing to the reference block derived by the above-described motion estimation can be used as the motion vector of the current block, and the mvp candidate having the motion vector with the smallest difference from the motion vector of the current block among the mvp candidates can be the selected mvp candidate. An MVD (motion vector difference), which is the difference obtained by subtracting the mvp from the motion vector of the current block, can be derived. In that case, information regarding the MVD can be signaled to the decoding device. Further, when the (A)MVP mode is applied, the value of the reference picture index is composed of reference picture index information and is separately signaled to the decoding device.
[0079] The encoding device derives residual samples based on the prediction samples (S410). The encoding device can derive the residual samples by comparing the original samples of the current block with the prediction samples.
[0080] The encoding device encodes video information including prediction information and residual information (S420). The encoding device can output the encoded video information in the form of a bitstream. The prediction information is information related to the prediction procedure, and includes prediction mode information (e.g., skip flag, merge flag, or mode index, etc.) and information related to motion information. The information related to the motion information includes candidate selection information (e.g., merge index, mvp flag, or mvp index) which is information for deriving a motion vector. Also, the information related to the motion information includes information related to the aforementioned MVD and / or reference picture index information. Also, the information related to the motion information includes information indicating whether L0 prediction, L1 prediction, or bi-prediction is applied. The residual information is information related to the residual samples. The residual information includes information related to the quantized transform coefficients for the residual samples.
[0081] The output bitstream can be stored in a (digital) storage medium and transmitted to the decoding device, or can also be transmitted to the decoding device via a network.
[0082] On the other hand, as described above, the encoding device can generate a reconstructed picture (including reconstructed samples and reconstructed blocks) based on the reference samples and the residual samples. This is because the same prediction result as that performed in the decoding device is derived in the encoding device, thereby improving the coding efficiency. Therefore, the encoding device can store the reconstructed picture (or reconstructed samples, reconstructed blocks) in the memory and utilize it as a reference picture for inter prediction. As described above, loop filter filtering procedures and the like can be further applied to the reconstructed picture.
[0083] The video / video decoding procedure based on inter prediction generally includes, for example, the following.
[0084] FIG. 5 shows an example of an inter-prediction based video / video decoding method.
[0085] As shown in FIG. 5, the decoding device can perform operations corresponding to the operations performed in the encoding device. The decoding device can perform prediction on the current block based on the received prediction information and derive a prediction sample.
[0086] Specifically, the decoding device determines a prediction mode for the current block based on the received prediction information (S500). The decoding device determines which inter-prediction mode is applied to the current block based on the prediction mode information in the prediction information.
[0087] For example, based on the merge flag, it can be determined whether the merge mode or (A) MVP mode is applied to the current block. Alternatively, based on the mode index, any one of various inter-prediction mode candidates can be selected. The inter-prediction mode candidates include a skip mode, a merge mode, and / or (A) MVP mode, or various inter-prediction modes described later.
[0088] The decoding device derives motion information of the current block based on the determined inter-prediction mode (S510). For example, when the skip mode or the merge mode is applied to the current block, the decoding device constructs a merge candidate list described later and can select any one of the merge candidates included in the merge candidate list. The selection is performed based on the aforementioned selection information (merge index). The motion information of the selected merge candidate can be used to derive the motion information of the current block. The motion information of the selected merge candidate can be used as the motion information of the current block.
[0089] As another example, when the (A) MVP mode is applied to the current block, the decoding device configures the (A) MVP candidate list described below, and can use the motion vector of the selected mvp (motion vector predictor) candidate included in the (A) MVP candidate list as the mvp of the current block. The selection is performed based on the above-described selection information (mvp flag or mvp index). In this case, the MVD of the current block can be derived based on the information regarding the MVD, and the motion vector of the current block can be derived based on the mvp of the current block and the MVD. Also, the reference picture index of the current block can be derived based on the reference picture index information. In the reference picture list related to the current block, the picture pointed to by the reference picture index can be derived as the reference picture to be referred to for the inter prediction of the current block.
[0090] On the other hand, as described below, the motion information of the current block can be derived without configuring a candidate list. In this case, the motion information of the current block can be derived according to the procedure disclosed in the prediction mode described below. In this case, the configuration of the candidate list as described above may be omitted.
[0091] The decoding device generates a prediction sample for the current block based on the motion information of the current block (S520). In this case, the reference picture can be derived based on the reference picture index of the current block, and the prediction sample of the current block can be derived using the sample of the reference block pointed to by the motion vector of the current block on the reference picture. In this case, as described below, depending on the case, a procedure for predicting sample filtering may be further performed on all or part of the prediction samples of the current block.
[0092] For example, the inter prediction unit of the decoding device includes a prediction mode determination unit, a motion information derivation unit, and a prediction sample derivation unit. The prediction mode for the current block is determined based on the prediction mode information received by the prediction mode determination unit. The motion information (such as a motion vector and / or a reference picture index) of the current block is derived based on the information related to the motion information received by the motion information derivation unit. The prediction sample derivation unit can derive the prediction sample of the current block.
[0093] The decoding device generates a residual sample for the current block based on the received residual information (S530). The decoding device generates a restored sample for the current block based on the prediction sample and the residual sample, and generates a restored picture based on this (S540). As described above, an in-loop filtering procedure or the like can be further applied to the restored picture.
[0094] FIG. 6 exemplarily shows an inter prediction procedure.
[0095] As shown in FIG. 6, as described above, the inter prediction procedure includes an inter prediction mode determination step, a motion information derivation step according to the determined prediction mode, and a prediction execution (prediction sample generation) step based on the derived motion information. The inter prediction procedure is performed in the encoding device and the decoding device as described above. In this document, the coding device includes an encoding device and / or a decoding device.
[0096] As shown in FIG. 6, the coding device determines an inter prediction mode for the current block (S600). Various inter prediction modes are used for predicting the current block within the picture. For example, various modes such as a merge mode, a skip mode, an MVP (motion vector prediction) mode, an Affine mode, a sub-block merge mode, an MMVD (merge with MVD) mode, an HMVP (historical motion vector prediction) mode, etc. can be used. A DMVR (decoder side motion vector refinement) mode, an AMVR (adaptive motion vector resolution) mode, a BCW (Bi-prediction with CU-level weight), a BDOF (Bi-directional optical flow), etc. can be used further or instead as accompanying modes. The Affine mode may be called the "affine motion prediction mode". The MVP mode may be called the "AMVP (advanced motion vector prediction) mode". In this document, some modes and / or motion information candidates derived by some modes may be included as one of the motion information related candidates of other modes. For example, the HMVP candidate may be added as a merge candidate of the merge / skip mode, or may be added as an mvp candidate of the MVP mode.
[0097] Prediction mode information indicating an inter prediction mode of a current block can be signaled from an encoding device to a decoding device. The prediction mode information is included in a bitstream and received by the decoding device. The prediction mode information includes index information indicating one of a number of candidate modes. Alternatively, the inter prediction mode can be indicated via hierarchical signaling of flag information. In this case, the prediction mode information includes one or more flags. For example, a skip flag is signaled to indicate whether to apply the skip mode, and when the skip mode is not applied, a merge flag is signaled to indicate whether to apply the merge mode, and when the merge mode is not applied, it may be indicated to apply the MVP mode, or additional flags for further classification may be signaled. The affine mode may be signaled as an independent mode, or may be signaled as a dependent mode such as the merge mode or the MVP mode. For example, the affine mode may include an affine merge mode and an affine MVP mode.
[0098] On the one hand, information indicating whether the above-mentioned list0 (L0) prediction, list1 (L1) prediction, or bi-prediction is used for the current block (current coding unit) is signaled. The said information may be referred to as motion prediction direction information, inter prediction direction information, or inter prediction indication information, and can be configured / encoded / signaled, for example, in the form of an inter_pred_idc syntax element. That is, the inter_pred_idc syntax element can indicate whether the above-mentioned list0 (L0) prediction, list1 (L1) prediction, or bi-prediction is used for the current block (current coding unit). In this document, for the sake of convenience of explanation, the inter prediction type (L0 prediction, L1 prediction, or BI prediction) indicated by the inter_pred_idc syntax element can be displayed as the motion prediction direction. L0 prediction may be displayed as pred_L0, L1 prediction may be displayed as pred_L1, and bi-prediction may be displayed as pred_BI. For example, the following prediction types can be indicated according to the value of the inter_pred_idc syntax element.
[0099] As described above, one picture includes one or more slices. A slice has one type among slice types including I (intra) slice, P (predictive) slice, and B (bi-predictive) slice. The said slice type is indicated based on the slice type information. For blocks within an I slice, inter prediction is not used for prediction, and only intra prediction is used. Of course, in this case as well, the original sample value can be coded and signaled without prediction. For blocks within a P slice, intra prediction or inter prediction is used, and when inter prediction is used, only uni prediction is used. On the other hand, for blocks within a B slice, intra prediction or inter prediction is used, and when inter prediction is used, up to maximum bi-prediction is used.
[0100] L0 and L1 include reference pictures that have been encoded / decoded before the current picture. For example, L0 includes reference pictures before and / or after the current picture in POC order, and L1 includes reference pictures after and / or before the current picture in POC order. In this case, a relatively lower reference picture index is assigned to L0 for reference pictures that are further before the current picture in POC order, and a relatively lower reference picture index is assigned to L1 for reference pictures that are further after the current picture in POC order. In the case of B slices, bi-prediction is applied, and in this case, either uni-directional bi-prediction or bi-directional bi-prediction can also be applied. Bi-directional bi-prediction may also be referred to as true bi-prediction.
[0101] Specifically, for example, information regarding the inter-prediction mode of the current block is coded and signaled at a level such as CU (CU syntax), or is implicitly determined according to conditions. In this case, for some modes, it is explicitly signaled, and for some of the remaining modes, it can be implicitly derived.
[0102] For example, the CU syntax can carry information regarding the (inter) prediction mode as shown in Table 1 below.
[0103]
Table 1-1
[0104]
Table 1-2
[0105]
Table 1-3
[0106]
Table 1-4
[0107]
Table 1-5
[0108]
Table 1-6
[0109]
Table 1-7
[0110]
Table 1-8
[0111]
Table 1-9
[0112]
Table 1-10
[0113]
Table 1-11
[0114]
Table 1-12
[0115]
Table 1-13
[0116] Here, cu_skip_flag indicates whether the skip mode is applied to the current block (CU).
[0117] If the value of pred_mode_flag is 0, it indicates that the current coding unit is coded in inter prediction mode. If the value of pred_mode_flag is 1, it indicates that the current coding unit is coded in intra prediction mode (pred_mode_flag equal to 0 specifies that the current coding unit is coded in inter prediction mode. pred_mode_flag equal to 1 specifies that the current coding unit is coded in intra prediction mode.).
[0118] If the value of pred_mode_ibc_flag is 1, it indicates that the current coding unit is coded in IBC prediction mode. If the value of pred_mode_ibc_flag is 0, it indicates that the current coding unit is not coded in IBC prediction mode (pred_mode_ibc_flag equal to 1 specifies that the current coding unit is coded in IBC prediction mode. pred_mode_ibc_flag equal to 0 specifies that the current coding unit is not coded in IBC prediction mode.).
[0119] When the value of pcm_flag[x0][y0] is 1, it indicates that the pcm_sample( ) syntax structure exists and the transform_tree( ) syntax structure does not exist in the coding unit including the luma coding block at the location (x0, y0). When pcm_flag[x0][y0] is 0, it indicates that the pcm_sample( ) syntax structure does not exist. (pcm_flag[x0][y0] equal to 1 specifies that the pcm_sample( ) syntax structure is present and the transform_tree( ) syntax structure is not present in the coding unit including the luma coding block at the location (x0, y0). pcm_flag[x0][y0] equal to 0 specifies that pcm_sample( ) syntax structure is not present.) That is, pcm_flag indicates whether the PCM (pulse coding modulation) mode is applied to the current block. When the PCM mode is applied to the current block, prediction, transformation, quantization, etc. are not applied, and the values of the original samples in the current block are coded and signaled.
[0120] If the value of intra_mip_flag[x0][y0] is 1, it indicates that the intra prediction type for luma samples is matrix-based intra prediction (MIP). If intra_mip_flag[x0][y0] is 0, it indicates that the intra prediction type for luma samples is not matrix-based intra prediction (intra_mip_flag[x0][y0] equal to 1 specifies that the intra prediction type for luma samples is matrix-based intra prediction (MIP). intra_mip_flag[x0][y0] equal to 0 specifies that the intra prediction type for luma samples is not matrix-based intra prediction.). That is, intra_mip_flag indicates whether the MIP prediction mode (type) is applied to the current block (luma samples).
[0121] intra_chroma_pred_mode[x0][y0] specifies the intra prediction mode for chroma samples in the current block.
[0122] general_merge_flag[x0][y0] indicates whether the inter prediction parameters for the current coding unit are inferred from a neighbouring inter-predicted partition. That is, general_merge_flag indicates that general merge is available. When the value of general_merge_flag is 1, regular merge mode, mmvd mode, and merge subblock mode (subblock merge mode) are available. For example, when the value of general_merge_flag is 1, the merge data syntax is parsed from the encoded video / image information (or bitstream), and the merge data syntax is configured / coded to include information as shown in Table 2 below.
[0123]
Table 2-1
[0124]
Table 2-2
[0125]
Table 2-3
[0126] Here, if the value of regular_merge_flag[x0][y0] is 1, it indicates that the inter prediction parameters of the current coding unit are generated using the regular merge mode (regular_merge_flag[x0][y0] equal to 1 specifies that regular merge mode is used to generate the inter prediction parameters of the current coding unit). That is, regular_merge_flag indicates whether the merge mode (regular merge mode) is applied to the current block.
[0127] If the value of mmvd_merge_flag[x0][y0] is 1, it indicates that the merge mode with motion vector difference is used to generate the inter prediction parameters of the current coding unit (mmvd_merge_flag[x0][y0] equal to 1 specifies that merge mode with motion vector difference is used to generate the inter prediction parameters of the current coding unit). That is, mmvd_merge_flag indicates whether MMVD is applied to the current block.
[0128] mmvd_cand_flag[x0][y0] specifies whether the first (0) or the second (1) candidate in the merging candidate list is used with the motion vector difference derived from mmvd_distance_idx[x0][y0] and mmvd_direction_idx[x0][y0].
[0129] mmvd_distance_idx[x0][y0] specifies the index used to derive MmvdDistance[x0][y0].
[0130] mmvd_direction_idx[x0][y0] specifies index used to derive MmvdSign[x0][y0].
[0131] merge_subblock_flag[x0][y0] specifies whether the subblock-based inter prediction parameters for the current coding. That is, merge_subblock_flag indicates whether the subblock merge mode (or, affine merge mode) is applied to the current block.
[0132] merge_subblock_idx[x0][y0] specifies the merging candidate index of the subblock-based merging candidate list.
[0133] ciip_flag[x0][y0] specifies whether the combined inter-picture merge and intra-picture prediction is applied for the current coding unit.
[0134] merge_triangle_idx0[x0][y0] specifies the first merging candidate index of the triangular shape based motion compensation candidate list.
[0135] merge_triangle_idx1[x0][y0] specifies the second merging candidate index of the triangular shape based motion compensation candidate list.
[0136] merge_idx[x0][y0] specifies the merging candidate index of the merging candidate list.
[0137] On the other hand, referring again to the CU syntax of Table 1, mvp_l0_flag[x0][y0] specifies the motion vector predictor index of list 0. That is, mvp_l0_flag indicates the candidate selected for the MVP derivation of the current block in the MVP candidate list 0 when the MVP mode is applied.
[0138] mvp_l1_flag[x0][y0] has the same semantics as mvp_l0_flag, with l0, L0 and list 0 replaced by l1, L1 and list 1, respectively.
[0139] inter_pred_idc[x0][y0] specifies whether list0, list1, or bi-prediction is used for the current coding unit.
[0140] If the value of sym_mvd_flag[x0][y0] is 1, it specifies the syntax elements ref_idx_l0[x0][y0] and ref_idx_l1[x0][y0], and that the mvd_coding(x0, y0, refList, cpIdx) syntax structure for refList equal to 1 is not present. That is, sym_mvd_flag indicates whether symmetric MVD is used in mvd coding.
[0141] ref_idx_l0[x0][y0] specifies the list 0 reference picture index for the current coding unit.
[0142] ref_idx_l1[x0][y0] has the same semantics as ref_idx_l0, with l0, L0 and list 0 replaced by l1, L1 and list 1, respectively.
[0143] inter_affine_flag[x0][y0] equal to 1 specifies that for the current coding unit, when decoding a P or B slice, affine model based motion compensation is used to generate the prediction samples of the current coding unit.
[0144] If the value of cu_affine_type_flag[x0][y0] is 1, it indicates that when decoding a P or B slice for the current coding unit, 6-parameter affine model based motion compensation is used to generate the prediction samples of the current coding unit. If the value of cu_affine_type_flag[x0][y0] is 0, it indicates that 4-parameter affine model based motion compensation is used to generate the prediction samples of the current coding unit. (cu_affine_type_flag[x0][y0] equal to 1 specifies that for the current coding unit, when decoding a P or B slice, 6-parameter affine model based motion compensation is used to generate the prediction samples of the current coding unit. cu_affine_type_flag[x0][y0] equal to 0 specifies that 4-parameter affine model based motion compensation is used to generate the prediction samples of the current coding unit.)
[0145] amvr_flag[x0][y0] indicates the resolution of the motion vector difference. The array indices x0, y0 indicate the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture. When the value of amvr_flag[x0][y0] is 0, it indicates that the resolution of the motion vector difference is 1 / 4 of a luma sample. When the value of amvr_flag[x0][y0] is 1, it indicates that the resolution of the motion vector difference is further indicated by amvr_precision_flag[x0][y0].
[0146] If the value of amvr_precision_flag[x0][y0] is 0, when the value of inter_affine_flag[x0][y0] is 0, it indicates that the resolution of the motion vector difference is one integer luma sample, and otherwise it indicates that it is 1 / 16 of a luma sample. If the value of amvr_precision_flag[x0] is 1, when the value of inter_affine_flag[x0][y0] is 0, it indicates that the resolution of the motion vector difference is four luma samples, and otherwise it indicates that it is one integer luma sample. The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture. (amvr_precision_flag[x0][y0] equal to 0 specifies that the resolution of the motion vector difference is one integer luma sample if inter_affine_flag[x0][y0] is equal to 0, and 1 / 16 of a luma sample otherwise. amvr_precision_flag[x0][y0] equal to 1 specifies that the resolution of the motion vector difference is four luma samples if inter_affine_flag[x0][y0] is equal to 0, and one integer luma sample otherwise. The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture.)
[0147] bcw_idx[x0][y0] specifies the weight index of bi-prediction with CU weights.
[0148] When the (inter) prediction mode for the current block is determined, the coding device derives motion information for the current block based on the prediction mode (S610).
[0149] The coding device performs inter prediction using the motion information of the current block. The encoding device can derive optimal motion information for the current block through a motion estimation procedure. For example, the encoding device can search for a highly correlated similar reference block within a determined search range in the reference picture in fractional pixel units using the original block in the original picture for the current block, thereby deriving motion information. The similarity of the blocks is derived based on the difference in sample values based on phase. For example, the similarity of the blocks is calculated based on the SAD between the current block (or a template of the current block) and the reference block (or a template of the reference block). In this case, the motion information can be derived based on the reference block with the minimum SAD within the search area. The derived motion information is signaled to the decoding device in various ways based on the inter prediction mode.
[0150] When the motion information for the current block is derived, the coding device performs inter prediction based on the motion information for the current block (S620). The coding device can derive prediction sample(s) for the current block based on the motion information. The current block including the prediction sample may be called a predicted block.
[0151] Based on the derived prediction samples, restored samples and restored pictures are generated, and then procedures such as in-loop filtering can be performed.
[0152] FIG. 7 is a diagram for explaining the merge mode and skip mode that can be used for inter prediction.
[0153] When the merge mode is applied during inter prediction, the motion information of the current block is not directly transmitted, but the motion information of the current block is induced using the motion information of the surrounding prediction blocks. Therefore, the encoding device can indicate the motion information of the current block by transmitting flag information indicating that the merge mode is used and a merge index indicating which surrounding prediction block is used. The merge mode may be called a regular merge mode.
[0154] The coding device searches for a merge candidate block used to induce the motion information of the current block in order to perform the merge mode. For example, up to 5 merge candidate blocks can be used, but this embodiment is not limited thereto. Also, information regarding the maximum number of the merge candidate blocks can be transmitted in the slice header or tile group header, but this embodiment is not limited thereto. After finding the merge candidate block, the coding device can generate a merge candidate list and select the merge candidate block having the minimum cost among them as the final merge candidate block.
[0155] This document provides various embodiments for the merge candidate blocks constituting the merge candidate list.
[0156] The merge candidate list includes, for example, five merge candidate blocks. For example, four spatial merge candidates and one temporal merge candidate can be used. As a specific example, in the case of spatial merge candidates as well, the blocks shown in FIG. 7 (A 0 , A 1 , B 0 , B 1 , B 2 ) can be used as spatial merge candidates. Hereinafter, the spatial merge candidate or the spatial MVP candidate described later may be referred to as SMVP, and the temporal merge candidate or the temporal MVP candidate described later may be referred to as TMVP.
[0157] The merge candidate list for the current block is configured based on, for example, the following procedure.
[0158] FIG. 8 schematically shows a method for configuring a merge candidate list.
[0159] First, the coding device (encoding device / decoding device) searches for spatial neighboring blocks of the current block and inserts the derived spatial merge candidates into the merge candidate list (S810). For example, the spatial neighboring blocks include the lower left corner neighboring block (A 0 ) of the current block, the left neighboring block (A 1 ), the upper right corner neighboring block (B 0 ), the upper neighboring block (B 1 ), and the upper left corner neighboring block (B 2 ) of the current block. However, this is an example, and additional neighboring blocks such as the right neighboring block, the lower neighboring block, and the lower right corner neighboring block can be further used as the spatial neighboring blocks in addition to the above-described spatial neighboring blocks. The coding device searches for the spatial neighboring blocks based on the priority to detect available blocks, and derives the motion information of the detected blocks as the spatial merge candidates. For example, the encoding device and / or the decoding device uses the five blocks shown in FIG. 7 as A1 , B 1 , B 0 , A 0 , B 2 Search in the order of, and by sequentially indexing available candidates, a merge candidate list can be constructed.
[0160] Also, the coding device inserts the temporal merge candidates derived by searching the temporal neighboring blocks of the current block into the merge candidate list (S820). The temporal neighboring blocks may be located on a reference picture that is a picture different from the current picture in which the current block is located. The reference picture on which the temporal neighboring blocks are located may be called a collocated picture or a col picture. The temporal neighboring blocks can be searched in the order of the peripheral blocks of the lower right corner and the lower right center block of the co-located block with respect to the current block on the col picture.
[0161] On the one hand, when motion data compression is applied, specific motion information can be stored as representative motion information for each fixed storage unit in the col picture. In this case, it is not necessary to store the motion information for all blocks within the fixed storage unit, thereby obtaining a motion data compression effect. In this case, the fixed storage unit may be predetermined, for example, in units of 16×16 samples or 8×8 samples, or size information regarding the fixed storage unit may be signaled from the encoding device to the decoding device. When the motion data compression is applied, the motion information of the temporally adjacent blocks may be replaced with the representative motion information of the fixed storage unit in which the temporally adjacent blocks are located. That is, in this case, from the perspective of implementation, instead of the prediction block located at the coordinates of the temporally adjacent blocks, based on the coordinates (upper left sample position) of the temporally adjacent blocks, after arithmetic right shift by a certain value and then arithmetic left shift, the motion information of the prediction block covering the arithmetically left-shifted position can be used to derive the temporal merge candidate. For example, when the fixed storage unit is n ×2 n sample units, if the coordinates of the temporally adjacent blocks are (xTnb, yTnb), the motion information of the prediction block located at the corrected position ((xTnb>>n)<<n), (yTnb>>n)<<n)) can be used for the temporal merge candidate. Specifically, for example, when the fixed storage unit is 16×16 sample units and the coordinates of the temporally adjacent blocks are (xTnb, yTnb), the motion information of the prediction block located at the corrected position ((xTnb>>4)<<4), (yTnb>>4)<<4)) can be used for the temporal merge candidate. Or, for example, when the fixed storage unit is 8×8 sample units and the coordinates of the temporally adjacent blocks are (xTnb, yTnb), the motion information of the prediction block located at the corrected position ((xTnb>>3)<<3), (yTnb>>3)<<3)) can be used for the temporal merge candidate.
[0162] On the one hand, the coding device checks whether the number of current merge candidates is less than the number of maximum merge candidates (S830). The number of the maximum merge candidates is defined in advance or signaled from the coding device to the decoding device. For example, the coding device generates information regarding the number of the maximum merge candidates, encodes it, and transmits it to the decoding device in the form of a bitstream. When the number of the maximum merge candidates is filled, the subsequent candidate addition process may not be performed.
[0163] As a result of the check, if the number of current merge candidates is less than the number of maximum merge candidates, the coding device inserts additional merge candidates into the merge candidate list (S840). The additional merge candidates may include, for example, at least one of history based merge candidate(s), pair-wise average merge candidate(s), ATMP, combined bi-predictive merge candidate(s) (when the slice / tile / group type of the current slice / tile / group is of type B), and / or zero vector merge candidate.
[0164] As a result of the check, if the number of current merge candidates is not less than the number of maximum merge candidates, the coding device terminates the configuration of the merge candidate list (S850). In this case, the coding device can select the optimal merge candidate among the merge candidates that configure the merge candidate list based on the rate-distortion (RD) cost, and can signal selection information (e.g., merge index) indicating the selected merge candidate to the decoding device. The decoding device can select the optimal merge candidate based on the merge candidate list and the selection information.
[0165] As described above, the motion information of the selected merge candidate can be used as the motion information of the current block, and the predicted sample of the current block can be derived based on the motion information of the current block. The encoding device can derive the residual sample of the current block based on the predicted sample, and can signal the residual information regarding the residual sample to the decoding device. As described above, the decoding device can generate a restored sample based on the residual sample derived based on the residual information and the predicted sample, and can generate a restored picture based on this.
[0166] When the skip mode is applied during inter prediction, the motion information of the current block can be derived in the same manner as when the above-described merge mode is applied. However, when the skip mode is applied, the residual signal for the corresponding block is omitted, and thus the predicted sample can be immediately used as the restored sample.
[0167] In addition to merge mode, where the implicitly derived motion information is directly used for prediction samples generation of the current CU, the merge mode with motion vector differences (MMVD) is introduced in VVC. Because similar motion information derivation methods are used for the skip mode and the merge mode, MMVD may be applied to the skip mode. A MMVD flag (ex. mmvd_flag) may be singnaled right after sending a skip flag and merge flag to specify whether MMVD mode is used for a CU.
[0168] In MMVD, after a merge candidate is selected, it is further refined by the signaled MVDs information. When MMVD is applied to the current block (i.e. when the mmvd_flag is equal to 1), further information for the MMVD may be signaled.
[0169] The further information includes a merge candidate flag (ex. mmvd_merge_flag) indicating whether the first (0) or the second (1) candidate in the merging candidate list is used with the motion vector difference, an index to specify motion magnitude (ex. mmvd_distance_idx), and an index for indication of motion direction (ex. mmvd_direction_idx). In MMVD mode, one for the first two candidates in the merge list is selected to be used as MV basis. The merge candidate flag is signaled to specify which one is used.
[0170] Distance index specifies motion magnitude information and indicate the pre-defined offset from the starting point.
[0171] An offset is added to either horizontal component or vertical component of starting MV. The relation of distance index and pre-defined offset is specified in Table 3.
[0172]
Table 3
[0173] Here, slice_fpel_mmvd_enabled_flag equal to 1 specifies that merge mode with motion vector difference uses integer sample precision in the current slice. slice_fpel_mmvd_enabled_flag equal to 0 specifies that merge mode with motion vector difference can use fractional sample precision in the current slice. When not present, the value of slice_fpel_mmvd_enabled_flag is inferred to be 0. slice_fpel_mmvd_enabled_flag syntax element may be signaled through (may be comprised in) a slice header.
[0174] The direction index represents the direction of the MVD relative to the starting point. The direction index can represent of the four directions as shown in Table4. It's noted that the meaning of MVD sign could be variant according to the information of starting MVs. When the starting MVs is an un-prediction MV or bi-prediction MVs with both lists point to the same side of the current picture (i.e. POCs of two references are both larger than the POC of the current picture, or are both smaller than the POC of the current picture), the sign in Table 4 specifies the sign of MV offset added to the starting MV.When the starting MVs is bi-prediction MVs with the two MVs point to the different sides of the current picture (i.e. the POC of one reference is larger than the POC of the current picture, and the POC of the other reference is smaller than the POC of the current picture), the sign in Table 4 specifies the sign of MV offset added to the list0 MV component of starting MV and the sign for the list1 MV has opposite value.
[0175]
Table 4
[0176] Both components of the merge plus MVD offset MmvdOffset[x0][y0] are derived as follows.
[0177]
Equation
[0178] FIG. 9 is a diagram for explaining a sub-block-based temporal motion vector prediction process that can be used during inter prediction.
[0179] A sub-block-based temporal motion vector prediction (SbTMVP) method can be used for inter prediction. Similar to the temporal motion vector prediction (TMVP), SbTMVP uses the motion field in the collocated picture to improve motion vector prediction and merge mode for CUs in the current picture. The same collocated picture used by TMVP is used for SbTVMP. SbTMVP differs from TMVP in the following two main aspects.
[0180] 1. TMVP predicts motion at the CU level but SbTMVP predicts motion at the sub-CU level.
[0181] 2. While TMVP fetches the temporal motion vectors from the collocated block in the collocated picture (the collocated block is the bottom - right or center (below - right center) block relative to the current CU), SbTMVP applies a motion shift before fetching the temporal motion information from the collocated picture, where the motion shift is obtained from the motion vector from one of the spatial neighbouring blocks of the current CU.
[0182] SbTMVP predicts the motion vectors of the sub-CUs within the current CU in two steps. In the first step, the spatial neighbour A1 is examined. If A1 has a motion vector that uses the collocated picture as its reference picture is identified, this motion vector (may be referred to as a temporal MV (tempMV)) is selected to be the motion shift to be applied. If no such motion is identified, then the motion shift is set to (0, 0).
[0183] In the second step, the motion shift identified in Step 1 is applied (i.e. added to the current block's coordinates) to obtain sub-CU-level motion information (motion vectors and reference indices) from the collocated picture as shown in Figure 9. The example in Figure 9 assumes the motion shift is set to block A1's motion. Then, for each sub-CU, the motion information of its corresponding block (the smallest motion grid that covers the center sample) in the collocated picture is used to derive the motion information for the sub-CU.The center sample (below right center sample) may correspond to a below-right sample among 4 central samples in the sub-CU when the sub-block has even length width and height.
[0184] After the motion information of the collocated sub-CU is identified, it is converted to the motion vectors and reference indices of the current sub-CU in a similar way as the TMVP process, where temporal motion scaling may be applied to align the reference pictures of the temporal motion vectors to those of the current CU.
[0185] A combined sub-block based merge list which contains both SbTVMP candidate and affine merge candidates may be used for the signalling of affine merge mode (may be referred to as sub-block (based) merge mode). The SbTVMP mode is enabled / disabled by a sequence parameter set (SPS) flag. If the SbTMVP mode is enabled, the SbTMVP predictor is added as the first entry of the list of sub-block merge candidates, and followed by the affine merge candidates. The maximum allowed size of the affine merge candidate list may be 5.
[0186] The sub-CU size used in SbTMVP may be fixed to be 8x8, and as done for affine merge mode, SbTMVP mode may be only applicable to the CU with both width and height are larger than or equal to 8.
[0187] The encoding logic of the additional SbTMVP merge candidate is the same as for the other merge candidates, that is, for each CU in P or B slice, an additional RD check may be performed to decide whether to use the SbTMVP candidate.
[0188] On the one hand, a triangle partition mode may be used for inter prediction. The triangle partition mode may be only applied to CUs that are 8x8 or larger. The triangle partition mode is signalled using a CU-level flag as one kind of merge mode, with other merge modes including the regular merge mode, the MMVD mode, the CIIP mode and the subblock merge mode.
[0189] When this mode is used, a CU may be split evenly into two triangle-shaped partitions, using either the diagonal split or the anti-diagonal split. Each triangle partition in the CU is inter-predicted using its own motion; only uni-prediction is allowed for each partition, that is, each partition has one motion vector and one reference index. The uni-prediction motion constraint is applied to ensure that same as the conventional bi-prediction, only two motion compensated prediction are needed for each CU.
[0190] If triangle partition mode is used for the current CU, then a flag indicating the direction of the triangle partition (diagonal or anti-diagonal), and two merge indices (one for each partition) are further signalled. The number of maximum TPM candidate size is signalled explicitly at slice level and specifies syntax binarization for TMP merge indices. After predicting each of the triangle partitions, the sample values along the diagonal or anti-diagonal edge are adjusted using a blending processing with adaptive weights.This is the prediction signal for the whole CU, and transform and quantization process will be applied to the whole CU as in other prediction modes. Finally, the motion field of a CU predicted using the triangle partition mode is stored in 4x4 units. The triangle partition mode is not used in combination with SBT, that is, when the signalled triangle mode is equal to 1, the cu_sbt_flag is inferred to be 0 without signalling.
[0191] The uni-prediction candidate list is derived directly from the merge candidate list constructed as described above.
[0192] After predicting each triangle partition using its own motion, blending is applied to the two prediction signals to derive samples around the diagonal or anti-diagonal edge.
[0193] Also, combined inter and intra prediction can be applied to a current block. An additional flag (e.g., ciip_flag) may be signalled to indicate if the combined inter / intra prediction (CIIP) mode is applied to the current CU. For example, when a CU is coded in merge mode, if the CU contains at least 64 luma samples (that is, CU width times CU height is equal to or larger than 64), and if both CU width and CU height are less than 128 luma samples, the additional flag is signalled to indicate if the combined inter / intra prediction (CIIP) mode is applied to the current CU. As its name indicates, the CIIP prediction combines an inter prediction signal with an intra prediction signal.The inter prediction signal in the CIIP mode P_inter is derived using the same inter prediction process applied to regular merge mode; and the intra prediction signal P_intra is derived following the regular intra prediction process with the planar mode. Then, the intra and inter prediction signals are combined using weighted averaging, where the weight value is calculated depending on the coding modes of the top and left neighbouring blocks as follows.
[0194] If the top neighbor is available and intra coded, then set isIntraTop to 1, otherwise set isIntraTop to 0.
[0195] If the left neighbor is available and intra coded, then set isIntraLeft to 1, otherwise set isIntraLeft to 0.
[0196] If (isIntraLeft + isIntraLeft) is equal to 2, then wt is set to 3.
[0197] Otherwise, if (isIntraLeft + isIntraLeft) is equal to 1, then wt is set to 2.
[0198] Otherwise, set wt to 1.
[0199] The CIIP prediction is formed as follows.
[0200]
Number
[0201] On one hand, in the coding device, in order to generate a prediction block, motion information can be derived based on the aforementioned regular merge mode, skip mode, SbTMVP mode, MMVD mode, triangle partitioning mode (partitioning mode) and / or CIIP mode. Each mode is activated / deactivated via an on / off flag for each mode included in the sequence parameter set (SPS). If the on / off flag for a specific mode is deactivated, the encoding device does not signal the syntax explicitly transmitted for the prediction mode in units of CU or PU.
[0202] Therefore, when all or some of the specific modes for the merge / skip mode are deactivated in the existing operation process, there will be a problem of redundant signaling of the on / off flag. Therefore, in this document, in the process of selecting the merge mode applied to the current block based on the merge data syntax in Table 2, any one of the following methods is used to prevent the same information (flag) from being signaled redundantly.
[0203] The encoding device can signal a flag based on a sequence parameter set as shown in Table 5 to select a prediction mode that can be used in the process of deriving motion information. Each prediction mode is turned on / off based on the sequence parameter set in Table 5, and each syntax element of the merge data syntax in Table 2 is parsed or derived according to the flag in Table 5 and the conditions under which each mode can be used.
[0204]
Table 5-1
[0205]
Table 5-2
[0206]
Table 5-3
[0207]
Table 5-4
[0208]
Table 5-5
[0209]
Table 5-6
[0210]
Table 5-7
[0211]
Table 5-8
[0212]
Table 5-9
[0213]
Table 5-10
[0214] The following drawings are created to illustrate a specific example of this document. Since the names of specific devices and the names of specific signals / information described in the drawings are presented exemplarily, the technical features of this specification are not limited to the specific names used in the following drawings.
[0215] Figures 10 and 11 schematically show an example of a video / video encoding method and related components including an inter-prediction method according to an embodiment of this document.
[0216] The encoding method disclosed in FIG. 10 can be performed by the encoding apparatus 200 disclosed in FIG. 2. Specifically, for example, S1000 and S1010 in FIG. 10 are performed by the prediction unit 220 of the encoding apparatus 200, S1020 and S1030 are performed by the residual processing unit 230 of the encoding apparatus 200, and S1040 is performed by the entropy encoding unit 240 of the encoding apparatus 200. The encoding method disclosed in FIG. 10 includes the embodiments described above in this document.
[0217] Specifically, as shown in FIGS. 10 and 11, the prediction unit of the encoding apparatus can derive a prediction sample of the current block based on inter-prediction (S1000). As an example, the prediction unit of the encoding apparatus can derive a prediction sample for the current block using any one of the inter-prediction modes of the regular merge mode, skip mode, MMVD mode, sub-block merge mode, partitioning mode, and CIIP mode.
[0218] Here, the regular merge mode is defined as a mode that induces the motion information of the current block by using the motion information of surrounding blocks. The skip mode is defined as a mode that uses the predicted block as the restored block. The MMVD mode is applied to the merge mode or the skip mode, and is defined as a merge (or skip) mode that uses the motion vector difference. The sub-block merge mode is defined as a merge mode based on sub-blocks. The partitioning mode is defined as a mode that divides the current block into two partitions (diagonal or semi-diagonal) for prediction. The CIIP mode is defined as a mode that combines inter-picture merge and intra-picture prediction.
[0219] On the other hand, the prediction unit of the encoding device searches for a block similar to the current block within a certain region (search region) of the reference picture by motion estimation, and derives a reference block whose difference from the current block is the minimum or below a certain criterion, and based on this, can derive a reference picture index indicating the reference picture where the reference block is located. Also, a motion vector can be derived based on the positional difference between the reference block and the current block.
[0220] The prediction unit of the encoding device generates a prediction sample (predicted block) of the current block based on the prediction mode of the current block and the motion vector of the current block. Also, information regarding the prediction mode indicating the prediction mode is generated (S1010). Here, the information regarding the prediction mode includes inter / intra prediction classification information, inter prediction mode information, etc., and includes various syntax elements regarding this.
[0221] The residual processing unit of the encoding device derives a residual sample based on the original sample (original block) for the current block and the predicted sample (predicted block) for the current block (S1020). Further, information regarding the residual sample is generated based on the residual sample (S1030).
[0222] The encoding unit of the encoding device encodes video information including the information regarding the residual sample, the information regarding the prediction mode, etc. (S1040). The video information includes partitioning-related information, information regarding the prediction mode, residual information, in-loop filtering-related information, etc., and includes various syntax elements related thereto. The information encoded in the encoding of the encoding device is output in the form of a bitstream. The bitstream is transmitted to the decoding device via a network or a storage medium.
[0223] For example, the video information includes information regarding various parameter sets such as an adaptation parameter set (APS), a picture parameter set (PPS), a sequence parameter set (SPS), or a video parameter set (VPS). Further, the video information includes information regarding the prediction mode of the current block such as coding unit syntax, merge data syntax, etc. Here, the sequence parameter set includes a combined inter-picture merge and intra-picture prediction (CIIP) available flag (ciip enable flag), an available flag for the partitioning mode, etc. The syntax of the coding unit includes a CU skip flag indicating whether the skip mode is applied to the current block.
[0224] According to one embodiment, as an example, the encoding device can include a regular merge flag in the video information based on the condition based on the CIIP available flag and the condition based on the size of the current block so that the same syntax is not transmitted repeatedly. Here, the condition based on the size of the current block can be that the product of the height and width of the current block is 64 or more, and the height and width of the current block are each less than 128. The condition based on the CIIP available flag can be that the value of the CIIP available flag is 1. That is, the encoding device can signal the regular merge flag when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, and the value of the CIIP available flag is 1.
[0225] As another example, the encoding device can include the regular merge flag in the video information based on the condition based on the CU skip flag and the condition based on the size of the current block being satisfied. Here, the condition based on the CU skip flag can be that the value of the CU skip flag is 0. In other words, the encoding device can signal the regular merge flag when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, and the value of the CU skip flag is 0.
[0226] As another example, the encoding device can include the regular merge flag in the video information based on at least one of the condition based on the CIIP availability flag and the condition based on the CU skip flag being satisfied and a condition based on the size of the current block. Here, the condition based on the CIIP availability flag is when the value of the CIIP availability flag is 1. The condition based on the CU skip flag is when the value of the CU skip flag is 0. In other words, the encoding device can signal the regular merge flag when the product of the height of the current block and the width of the current block is 64 or more, the height of the current block and the width of the current block are each less than 128, the value of the CIIP availability flag is 1, or the value of the CU skip flag is 0.
[0227] As another example, in addition to the condition based on the CIIP availability flag and the condition based on the size of the current block, the encoding device can include the regular merge flag in the video information based on a further condition based on the CU skip flag being satisfied. Here, the condition based on the CU skip flag can be when the value of the CU skip flag is 0. In other words, the encoding device can signal the regular merge flag when the product of the height of the current block and the width of the current block is 64 or more, the height of the current block and the width of the current block are each less than 128, the value of the CIIP availability flag is 1, and the value of the CU skip flag is 0.
[0228] As another example, the encoding device can include a regular merge flag in the video information based on the condition that the information regarding the current block and the partitioning mode available flag are satisfied. Here, the condition based on the information regarding the current block includes the case where the product of the width and height of the current block is 64 or more and / or the type of the slice including the current block is a B slice. The condition based on the partitioning mode available flag can be the case where the value of the partitioning mode available flag is 1. That is, the encoding device can signal the regular merge flag when both the condition based on the height of the current block and the information regarding the current block and the condition based on the partitioning mode available flag are satisfied.
[0229] When the condition based on the CIIP available flag and the condition based on the size of the current block are not satisfied, the encoding device determines whether the condition based on the information regarding the current block and the partitioning mode available flag is satisfied. Alternatively, when the condition based on the information regarding the current block and the partitioning mode available flag is not satisfied, the encoding device determines whether the condition based on the CIIP available flag and the size of the current block is satisfied.
[0230] On the other hand, the encoding device may also signal the regular merge flag when the product of the width and height of the current block is not 32 and the value of the MMVD available flag is 1, or when the maximum number of sub-block merge candidates is greater than 0 and the width and height of the current block are each 8 or more.
[0231] For this purpose, as an example, the merge data syntax is configured as shown in Table 6 below.
[0232] [Table 6-1]
[0233]
Table 6-2
[0234]
Table 6-3
[0235] In Table 6, a value of 1 for the regular_merge_flag indicates that the regular merge mode is used to generate the inter prediction parameters of the current coding unit (current block) (regular_merge_flag[x0][y0] equal to 1 specifies that regular merge mode is used to generate the inter prediction parameters of the current coding unit). The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture (The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture.).
[0236] When regular_merge_flag[x0][y0] is not present, it is inferred as follows.
[0237] If all of the following conditions are true, regular_merge_flag[x0][y0] is inferred to be equal to 1.
[0238] - general_merge_flag[x0][y0] is equal to 1
[0239] - sps_mmvd_enable_flag is equal to 0 or cbWidth*cbHeight==32
[0240] - MaxNumSubblockMergeCand<=0 or cbWidth<8 or cbHeight<8
[0241] - sps_ciip_enabled_flag is equal to 0 or cbWidth*cbHeight<64 or cbWidth>=128 or cbHeight>=128 or cu_skip_flag[x0][y0] is equal to 1
[0242] - sps_triangle_enabled_flag is equal to 0 or MaxNumTriangleMergeCand<2 or slice_type is not equal to B_SLICE
[0243] Otherwise, regular_merge_flag[x0][y0] is inferred to be equal to 0.
[0244] According to another embodiment, as an example, the encoding apparatus may include an MMVD merge flag in the video information based on satisfaction of a condition based on the CIIP availability flag and a condition based on the size of the current block so that the same syntax is not repeatedly transmitted. Here, the condition based on the size of the current block may be a case where the product of the height and the width of the current block is 64 or more and the height and the width of the current block are each smaller than 128. The condition based on the CIIP availability flag may be a case where the value of the CIIP availability flag is 1. In other words, the encoding apparatus may signal the MMVD merge flag when the product of the height and the width of the current block is 64 or more, the height and the width of the current block are each smaller than 128, and the value of the CIIP availability flag is 1.
[0245] As another example, the encoding apparatus may include the MMVD merge flag in the video information based on further satisfaction of a condition based on the CU skip flag in addition to the condition based on the CIIP availability flag and the condition based on the size of the current block. Here, the condition based on the CU skip flag may be a case where the value of the CU skip flag is 0. That is, the encoding apparatus may signal the MMVD merge flag when the product of the height and the width of the current block is 64 or more, the height and the width of the current block are each smaller than 128, the value of the CIIP availability flag is 1, and the value of the CU skip flag is 0.
[0246] As another example, the encoding device can include an MMVD merge flag in the video information based on the condition that the information regarding the current block and the partitioning mode availability flag are satisfied. Here, the condition based on the information regarding the current block includes the case where the product of the width and height of the current block is 64 or more and / or the type of slice including the current block is a b slice. The condition based on the partitioning mode availability flag is the case where the value of the partitioning mode availability flag is 1. That is, the encoding device can signal an MMVD merge flag when both the condition based on the height of the current block, the condition based on the information regarding the current block, and the condition based on the partitioning mode availability flag are satisfied.
[0247] When the condition based on the CIIP availability flag and the condition based on the size of the current block are not satisfied, the encoding device can determine whether the condition based on the information regarding the current block and the partitioning mode availability flag is satisfied. Alternatively, when the condition based on the information regarding the current block and the partitioning mode availability flag is not satisfied, the encoding device can determine whether the condition based on the CIIP availability flag and the size of the current block is satisfied.
[0248] On the other hand, when the product of the width and height of the current block is not 32 and the value of the MMVD availability flag is 1, or when the maximum number of sub-block merge candidates is greater than 0 and the width and height of the current block are each 8 or more, the encoding device can also signal an MMVD merge flag.
[0249] For this purpose, as an example, the merge data syntax is configured as shown in Table 7 below.
[0250]
Table 7-1
[0251]
Table 7-2
[0252]
Table 7-3
[0253]
Table 7-4
[0254] A value of 1 for the MMVD merge flag indicates that the merge mode with motion vector difference is used to generate the inter prediction parameters of the current coding unit (current block) (mmvd_merge_flag[x0][y0] equal to 1 specifies that merge mode with motion vector difference is used to generate the inter prediction parameters of the current coding unit). The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture (The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture.).
[0255] When the MMVD merge flag is not present, it is inferred as follows.
[0256] If all of the following conditions are true, mmvd_merge_flag[x0][y0] is inferred to be equal to 1.
[0257] - general_merge_flag[x0][y0] is equal to 1
[0258] - regular_merge_flag[x0][y0] is equal to 0
[0259] - sps_mmvd_enable_flag is equal to 1
[0260] - cbWidth*cbHeight!=32
[0261] - MaxNumSubblockMergeCand<=0 or cbWidth<8 or cbHeight<8
[0262] - sps_ciip_enabled_flag is equal to 0 or cbWidth>=128 or cbHeight>=128 or cu_skip_flag[x0][y0] is equal to 1
[0263] - The value of the SPS partitioning available flag is 0 or the maximum number of partitioning merge candidates is less than 2 or the slice type is not B_SLICE (sps_triangle_enabled_flag is equal to 0 or MaxNumTriangleMergeCand<2 or slice_type is not equal to B_SLICE)
[0264] Otherwise, the value of the MMVD merge flag is inferred to be equal to 0.
[0265] On the other hand, according to another embodiment, as an example, the encoding device can include a merge sub-block flag in the video information based on the condition based on the CIIP available flag and the condition based on the size of the current block so that the same syntax is not transmitted repeatedly. Here, the condition based on the size of the current block is that the product of the height of the current block and the width of the current block is 64 or more, and the height of the current block and the width of the current block are each less than 128. The condition based on the CIIP available flag is that the value of the CIIP available flag is 1. In other words, the encoding device can signal the merge sub-block flag when the product of the height of the current block and the width of the current block is 64 or more, the height of the current block and the width of the current block are each less than 128, and the value of the CIIP available flag is 1.
[0266] As another example, in addition to the conditions based on the CIIP available flag and the size of the current block, the encoding device can include the remaining sub-block flag in the video information based on the condition that the condition based on the CU skip flag is further satisfied. Here, the condition based on the CU skip flag is the case where the value of the CU skip flag is 0. In other words, when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, the value of the CIIP available flag is 1, and the value of the CU skip flag is 0, the encoding device can signal the merge sub-block flag.
[0267] As yet another example, the encoding device can include the merge sub-block flag in the video information based on the condition that the condition based on the information about the current block and the partitioning mode available flag is satisfied. Here, the condition based on the information about the current block includes the case where the product of the width and height of the current block is 64 or more and / or the type of the slice including the current block is a B slice. The condition based on the partitioning mode available flag is the case where the value of the partitioning mode available flag is 1. That is, when both the condition based on the height of the current block, the condition based on the information about the current block, and the condition based on the partitioning mode available flag are satisfied, the encoding device can signal the merge sub-block flag.
[0268] When the conditions based on the CIIP available flag and the conditions based on the size of the current block are not satisfied, the encoding device can determine whether the conditions based on the information about the current block and the partitioning mode available flag are satisfied. Alternatively, when the conditions based on the information about the current block and the partitioning mode available flag are not satisfied, the encoding device can determine whether the conditions based on the CIIP available flag and the size of the current block are satisfied.
[0269] On the other hand, when the maximum number of sub-block merge candidates is greater than 0 and the width and height of the current block are each 8 or more, the encoding device can also signal the merge sub-block flag.
[0270] For this purpose, as an example, the merge data syntax is configured as shown in Table 8 below.
[0271]
Table 8-1
[0272]
Table 8-2
[0273]
Table 8-3
[0274] The merge_subblock_flag[x0][y0] specifies whether the subblock-based inter prediction parameters for the current coding unit are inferred from neighbouring blocks. The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture.
[0275] When merge_subblock_flag[x0][y0] is not present, it is inferred as follow.
[0276] If all of the following conditions are true, merge_subblock_flag[x0][y0] is inferred to be equal to 1.
[0277] - general_merge_flag[x0][y0] is equal to 1
[0278] - regular_merge_flag[x0][y0] is equal to 0
[0279] - The value of the merge sub-block flag is 0 (merge_subblock_flag[x0][y0] is equal to 0)
[0280] - The value of the MMVD merge flag is 0 (mmvd_merge_flag[x0][y0] is equal to 0)
[0281] - The maximum number of sub-block merge candidates is greater than 0 (MaxNumSubblockMergeCand>0)
[0282] - The width and height of the current block are each 8 or more (cbWidth>=8 and cbHeight>=8)
[0283] - The value of the SPS CIIP available flag is 0 or the width of the current block is 128 or more or the height of the current block is 128 or more or the value of the CU skip flag is 1 (sps_ciip_enabled_flag is equal to 0 or cbWidth>=128 or cbHeight>=128 or cu_skip_flag[x0][y0] is equal to 1)
[0284] - The value of the SPS partitioning available flag is 0 or the maximum number of partitioning merge candidates is less than 2 or the slice type is not a B slice (sps_triangle_enabled_flag is equal to 0 or MaxNumTriangleMergeCand<2 or slice_type is not equal to B_SLICE)
[0285] Otherwise, the value of the merge sub-block flag is derived as 0. (Otherwise, merge_subblock_flag[x0][y0] is inferred to be equal to 0.)
[0286] On the other hand, according to another embodiment, as an example, the encoding device can include the CIIP flag in the video information based on the condition based on the CIIP available flag and the condition based on the size of the current block so that the same syntax is not transmitted repeatedly. Here, the condition based on the size of the current block is that the product of the height and the width of the current block is 64 or more, and the height and the width of the current block can be less than 128 respectively. The condition based on the CIIP available flag is that the value of the CIIP available flag is 1. That is, the encoding device can signal the CIIP flag when the product of the height and the width of the current block is 64 or more, the height and the width of the current block are less than 128 respectively, and the value of the CIIP available flag is 1.
[0287] As another example, in addition to the condition based on the CIIP available flag and the condition based on the size of the current block, the encoding device can include the CIIP flag in the video information based on the condition based on the CU skip flag being further satisfied. Here, the condition based on the CU skip flag is that the value of the CU skip flag is 0. In other words, the encoding device can signal the CIIP flag when the product of the height and the width of the current block is 64 or more, the height and the width of the current block are less than 128 respectively, the value of the CIIP available flag is 1, and the value of the CU skip flag is 0.
[0288] As another example, the encoding device can include a CIIP flag in the video information based on the condition that the information regarding the current block and the partitioning mode available flag are satisfied. Here, the condition based on the information regarding the current block includes the case where the product of the width and height of the current block is 64 or more and / or the type of the slice including the current block is a B slice. The condition based on the partitioning mode available flag is the case where the value of the partitioning mode available flag is 1. In other words, the encoding device can signal a CIIP flag when both the condition based on the height of the current block, the condition based on the information regarding the current block, and the condition based on the partitioning mode available flag are satisfied.
[0289] When the condition based on the CIIP available flag and the condition based on the size of the current block are not satisfied, the encoding device determines whether the condition based on the information regarding the current block and the partitioning mode available flag is satisfied. Alternatively, when the condition based on the information regarding the current block and the partitioning mode available flag is not satisfied, the encoding device determines whether the condition based on the CIIP available flag and the size of the current block is satisfied.
[0290] For this purpose, as an example, the merge data syntax is configured as shown in Table 9 below.
[0291]
Table 9-1
[0292]
Table 9-2
[0293]
Table 9-3
[0294] The CIIP flag indicates whether the combined inter-picture merge and intra-picture prediction is applied to the current coding unit (ciip_flag[x0][y0] specifies whether the combined inter-picture merge and intra-picture prediction is applied for the current coding unit). The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture (The array indices x0, y0 specify the location (x0, y0) of the top-left luma sample of the considered coding block relative to the top-left luma sample of the picture).
[0295] When ciip_flag[x0][y0] is not present, it is inferred as follows.
[0296] If all of the following conditions are true, ciip_flag[x0][y0] is inferred to be equal to 1
[0297] - The value of the general_merge_flag is 1 (general_merge_flag[x0][y0] is equal to 1)
[0298] - The value of the regular_merge_flag is 0 (regular_merge_flag[x0][y0] is euqal to 0)
[0299] - The value of the merge sub-block flag is 0 (merge_subblock_flag[x0][y0] is equal to 0)
[0300] - The value of the MMVD merge flag is 0 (mmvd_merge_flag[x0][y0] is equal to 0)
[0301] - The value of the SPS CIIP available flag is 1 (sps_ciip_enabled_flag is equal to 1)
[0302] - The value of the CU skip flag is 0 (cu_skip_flag[x0][y0] is equal to 0)
[0303] - The product of the width and height of the current block is 64 or more, and the width and height of the current block are each less than 128 (cbWidth*cbHeight>=64 and cbWidth<128 and cbHeight<128)
[0304] - The value of the SPS partitioning available flag is 0 or the maximum number of partitioning merge candidates is less than 2 or the slice type is not a B slice (sps_triangle_enabled_flag is equal to 0 or MaxNumTriangleMergeCand<2 or slice_type is not equal to B_SLICE)
[0305] Otherwise, the value of the ciip flag is inferred to be 0 (Otherwise, ciip_flag[x0][y0] is inferred to be equal to 0.).
[0306] FIG. 12 and FIG. 13 schematically show an example of a video / video decoding method and related components including an inter-prediction method according to an embodiment of the present document.
[0307] The decoding method disclosed in FIG. 12 can be performed by the decoding apparatus 300 disclosed in FIGS. 3 and 13. Specifically, for example, S1200 and S1210 in FIG. 12 are performed in the entropy decoding unit 310 of the decoding apparatus, S1220 is performed in the prediction unit 330 of the decoding apparatus 300, and S1230 is performed by the addition unit 340 of the decoding apparatus 300. The decoding method disclosed in FIG. 12 includes the embodiments described above in this document.
[0308] As shown in FIGS. 12 and 13, the decoding apparatus acquires at least one of the CIIP available flag and the CU skip flag from the bitstream (S1200). Specifically, the entropy decoding unit 310 of the decoding apparatus can derive residual information and information related to the prediction mode from the signal received in the form of a bitstream from the encoding apparatus in FIG. 2. Here, the information related to the prediction mode may be referred to as prediction-related information. The information related to the prediction mode includes inter / intra prediction classification information, inter prediction mode information, etc., and can include various syntax elements related thereto.
[0309] The bitstream includes video information including information related to various parameter sets such as an adaptation parameter set (APS), a picture parameter set (PPS), a sequence parameter set (SPS), or a video parameter set (VPS). The video information further includes information related to the prediction mode of the current block, such as coding unit syntax, merge data syntax, etc. The sequence parameter set includes a CIIP available flag, a flag available for the partitioning mode, etc. The coding unit syntax includes a CU skip flag indicating whether the skip mode is applied to the current block.
[0310] The prediction unit 330 of the decoding device obtains a regular merge flag from the bitstream (S1210) based on at least one of the conditions based on the CIIP available flag, the conditions based on the CU skip flag, and the conditions based on the size of the current block. Further, based on the regular merge flag, an inter prediction is performed to generate prediction samples of the current block (S1220). For example, when the regular merge flag is parsed from the bitstream, the prediction unit 330 of the decoding device can perform inter prediction in the aforementioned (regular) merge mode. In this case, the prediction unit 330 of the decoding device can construct a merge candidate list via the procedure of FIG. 8 and select an optimal merge candidate using the merge index obtained from the bitstream. Also, the motion information of the optimal merge candidate can be used as the motion information of the current block to generate prediction samples of the current block.
[0311] On the other hand, the residual processing unit 320 of the decoding device can generate residual samples based on the residual information. The addition unit 340 of the decoding device generates restored samples based on the prediction samples generated in the prediction unit 330 and the residual samples generated in the residual processing unit 320 (S1230). The restored picture can be generated based on the restored samples. Thereafter, in-loop filtering procedures such as deblocking filtering, SAO, and / or ALF procedures can be applied to the restored picture to improve subjective / objective image quality as necessary.
[0312] As an example, in deriving the prediction mode of the current block, the decoding device can obtain the regular merge flag from the bitstream based on the condition based on the CIIP availability flag and the condition based on the size of the current block being satisfied. Here, the condition based on the size of the current block is that the product of the height and width of the current block is 64 or more, and the height and width of the current block are each less than 128. The condition based on the CIIP availability flag is that the value of the CIIP availability flag is 1. In other words, when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, and the value of the CIIP availability flag is 1, the decoding device can parse the regular merge flag from the merge data syntax included in the bitstream.
[0313] As another example, based on the condition that the CU skip flag and the condition based on the size of the current block are satisfied, the regular merge flag can be obtained from the bitstream. Here, the condition based on the size of the current block is that the product of the height and width of the current block is 64 or more, and the height and width of the current block are each less than 128. The condition based on the CU skip flag is that the value of the CU skip flag is 0. In other words, when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, and the value of the CU skip flag is 0, the decoding device can parse the regular merge flag from the merge data syntax included in the bitstream.
[0314] Also, as another example, the decoding device can obtain the regular merge flag from the bitstream based on at least one of the condition based on the CIIP available flag and the condition based on the CU skip flag being satisfied and the condition based on the size of the current block being satisfied. Here, the condition based on the CIIP available flag can be the case where the value of the CIIP available flag is 1. The condition based on the CU skip flag is the case where the value of the CU skip flag is 0. In other words, the decoding device can parse the regular merge flag from the merge data syntax when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, and the value of the CIIP available flag is 1 or the value of the CU skip flag is 0.
[0315] Also, as another example, in addition to the condition based on the CIIP available flag and the condition based on the size of the current block, the decoding device can obtain the regular merge flag from the bitstream based on the condition based on the CU skip flag being further satisfied. Here, the condition based on the CU skip flag is the case where the value of the CU skip flag is 0. In other words, the decoding device can parse the regular merge flag from the merge data syntax when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, the value of the CIIP available flag is 1, and the value of the CU skip flag is 0.
[0316] As another example, the decoding device can obtain the regular merge flag from the bitstream based on the condition that the information regarding the current block and the partitioning mode availability flag are satisfied. Here, the condition based on the information regarding the current block includes the case where the product of the width and height of the current block is 64 or more and / or the type of slice including the current block is a B slice. The condition based on the partitioning mode availability flag is the case where the value of the partitioning mode availability flag is 1. In other words, the decoding device can parse the regular merge flag from the merge data syntax when both the condition based on the height of the current block, the condition based on the information regarding the current block, and the condition based on the partitioning mode availability flag are satisfied.
[0317] When the condition based on the CIIP availability flag and the condition based on the size of the current block are not satisfied, the decoding device determines whether the condition based on the information regarding the current block and the partitioning mode availability flag is satisfied. Alternatively, the decoding device can determine whether the condition based on the CIIP availability flag and the condition based on the size of the current block are satisfied when the condition based on the information regarding the current block and the partitioning mode availability flag is not satisfied.
[0318] On the other hand, the decoding device may also parse the regular message flag from the bitstream when the product of the width and height of the current block is not 32, the value of the MMVD availability flag is 1, or the maximum number of sub-block merge candidates is greater than 0 and the width and height of the current block are each 8 or more. For this purpose, the merge data syntax is configured as shown in Table 6 above.
[0319] When there is no regular merge flag in the bitstream, the decoding device can derive the value of the regular merge flag as 1 if the value of the general merge flag is 1, the value of the MMVD available flag in the SPS is 0, or the product of the width and height of the current block is 32, the maximum number of sub-block merge candidates is 0 or less, or the width of the current block is less than 8, or the height of the current block is less than 8, the value of the CIIP available flag in the SPS is 0, or the product of the width and height of the current block is less than 64, or the width of the current block is 128 or more, or the value of the CU skip flag is 1, the value of the partitioning available flag in the SPS is 0, or the maximum number of partitioning merge candidates is less than 2, or the slice type is not a B slice. Otherwise, the value of the regular merge flag is derived as 0.
[0320] As another example, in deriving the prediction mode of the current block, the decoding device can obtain the MMVD merge flag from the bitstream based on the condition based on the CIIP available flag and the condition based on the size of the current block being satisfied. Here, the condition based on the size of the current block is that the product of the height and width of the current block is 64 or more, and the height and width of the current block can be less than 128 respectively. The condition based on the CIIP available flag is that the value of the CIIP available flag is 1. In other words, when the product of the height and width of the current block is 64 or more, the height and width of the current block are less than 128 respectively, and the value of the CIIP available flag is 1, the decoding device can parse the MMVD merge flag from the merge data syntax included in the bitstream.
[0321] As another example, based on the condition that the CU skip flag and the condition based on the size of the current block are satisfied, the MMVD merge flag can be obtained from the bitstream. Here, the condition based on the size of the current block is that the product of the height and width of the current block is 64 or more, and the height and width of the current block can be less than 128 respectively. The condition based on the CU skip flag is that the value of the CU skip flag is 0. In other words, when the product of the height and width of the current block is 64 or more, the height and width of the current block are less than 128 respectively, and the value of the CU skip flag is 0, the decoding device can parse the MMVD merge flag from the merge data syntax included in the bitstream.
[0322] As still another example, in addition to the condition based on the CIIP available flag and the condition based on the size of the current block, the decoding device can obtain the MMVD merge flag from the bitstream based on the further satisfaction of the condition based on the CU skip flag. Here, the condition based on the CU skip flag is that the value of the CU skip flag is 0. In other words, the decoding device can parse the MMVD merge flag from the merge data syntax when the product of the height and width of the current block is 64 or more, the height and width of the current block are less than 128 respectively, the value of the CIIP available flag is 1, and the value of the CU skip flag is 0.
[0323] As another example, the decoding device can obtain the MMVD merge flag from the bitstream based on the condition that the information regarding the current block and the partitioning mode available flag are satisfied. Here, the condition based on the information regarding the current block includes the case where the product of the width and height of the current block is 64 or more and / or the type of slice including the current block is a B slice. The condition based on the partitioning mode available flag is the case where the value of the partitioning mode available flag is 1. In other words, the decoding device can parse the MMVD merge flag from the merge data syntax when both the condition based on the height of the current block, the condition based on the information regarding the current block, and the condition based on the partitioning mode available flag are satisfied.
[0324] When the condition based on the CIIP available flag and the condition based on the size of the current block are not satisfied, the decoding device determines whether the condition based on the information regarding the current block and the partitioning mode available flag is satisfied. Alternatively, the decoding device can determine whether the condition based on the CIIP available flag and the condition based on the size of the current block are satisfied when the condition based on the information regarding the current block and the partitioning mode available flag is not satisfied.
[0325] On the other hand, the decoding device can also parse the MMVD merge flag from the bitstream when the product of the width and height of the current block is not 32 and the value of the MMVD available flag is 1, or when the maximum number of sub-block merge candidates is greater than 0 and the width and height of the current block are each 8 or more. For this purpose, the merge data syntax is configured as shown in Table 7 above.
[0326] When there is no MMVD merge flag in the bitstream, the decoding device sets the value of the general merge flag to 1, the value of the regular merge flag to 0, the value of the MMVD available flag in the SPS to 1, the product of the width and height of the current block is not 32, the maximum number of sub-block merge candidates is 0 or less, or the width of the current block is less than 8, or the height of the current block is less than 8, the value of the CIIP available flag in the SPS is 0, or the width of the current block is 128 or more, or the height of the current block is 128 or more, or the value of the CU skip flag is 1, the value of the partitioning available flag in the SPS is 0, or the maximum number of partitioning merge candidates is less than 2, or the slice type is not a B slice, the value of the MMVD merge flag can be derived as 1. Otherwise, the value of the MMVD merge flag can be derived as 0.
[0327] As another example, in deriving the prediction mode of the current block, the decoding device can obtain the merge sub-block flag from the bitstream based on the condition based on the CIIP available flag and the condition based on the size of the current block being satisfied. Here, the condition based on the size of the current block is that the product of the height and width of the current block is 64 or more, and the height and width of the current block can be less than 128 respectively. The condition based on the CIIP available flag is that the value of the CIIP available flag is 1. In other words, when the product of the height and width of the current block is 64 or more, the height and width of the current block are less than 128 respectively, and the value of the CIIP available flag is 1, the decoding device can parse the merge sub-block flag from the merge data syntax included in the bitstream.
[0328] As another example, based on the condition that the CU skip flag and the condition based on the size of the current block are satisfied, the merge sub-block flag can be obtained from the bitstream. Here, the condition based on the size of the current block is that the product of the height and the width of the current block is 64 or more, and the height and the width of the current block may be less than 128 respectively. The condition based on the CU skip flag is that the value of the CU skip flag is 0. In other words, when the product of the height and the width of the current block is 64 or more, the height and the width of the current block are less than 128 respectively, and the value of the CU skip flag is 0, the decoding device can parse the merge sub-block flag from the merge data syntax included in the bitstream.
[0329] As yet another example, in addition to the condition based on the CIIP availability flag and the condition based on the size of the current block, the decoding device can obtain the merge sub-block flag from the bitstream based on the further satisfaction of the condition based on the CU skip flag. Here, the condition based on the CU skip flag is that the value of the CU skip flag is 0. In other words, the decoding device can parse the merge sub-block flag from the merge data syntax when the product of the height and the width of the current block is 64 or more, the height and the width of the current block are less than 128 respectively, the value of the CIIP availability flag is 1, and the value of the CU skip flag is 0.
[0330] As another example, the decoding device can obtain the merge sub-block flag from the bitstream based on the condition that the information regarding the current block and the partitioning mode available flag are satisfied. Here, the condition based on the information regarding the current block includes the case where the product of the width and height of the current block is 64 or more and / or the type of the slice including the current block is a B slice. The condition based on the partitioning mode available flag is the case where the value of the partitioning mode available flag is 1. In other words, the decoding device can parse the merge sub-block flag from the merge data syntax when both the condition based on the height of the current block and the condition based on the information regarding the current block and the condition based on the partitioning mode available flag are satisfied.
[0331] When the condition based on the CIIP available flag and the condition based on the size of the current block are not satisfied, the decoding device can determine whether the condition based on the information regarding the current block and the partitioning mode available flag is satisfied. Alternatively, when the condition based on the information regarding the current block and the partitioning mode available flag is not satisfied, the decoding device can determine whether the condition based on the CIIP available flag and the condition based on the size of the current block are satisfied.
[0332] On the other hand, the decoding device can also parse the merge sub-block flag from the bitstream when the maximum number of sub-block merge candidates is greater than 0 and the width and height of the current block are each 8 or more. For this purpose, the merge data syntax is configured as shown in Table 8 above.
[0333] When there is no merge sub-block flag in the bitstream, the decoding device has the value of the general merge flag as 1, the value of the regular merge flag as 0, the value of the merge sub-block flag as 0, the value of the MMVD merge flag as 0, the maximum number of sub-block merge candidates is greater than 0, the width and height of the current block are each 8 or more, the value of the CIIP available flag in the SPS is 0 or the width of the current block is 128 or more or the height of the current block is 128 or more or the value of the CU skip flag is 1, and the value of the partitioning available flag in the SPS is 9 or the maximum number of partitioning merge candidates is less than 2 or the slice type is not a B slice, the value of the merge sub-block flag can be derived as 1. Otherwise, the value of the merge sub-block flag can be derived as 0.
[0334] As another example, in the derivation of the prediction mode of the current block, the decoding device can obtain the CIIP flag from the bitstream based on the condition based on the CIIP available flag and the condition based on the size of the current block being satisfied. Here, the condition based on the size of the current block is that the product of the height and width of the current block is 64 or more, and it can be the case where the height and width of the current block are each less than 128. The condition based on the CIIP available flag is that the value of the CIIP available flag is 1. In other words, when the product of the height and width of the current block is 64 or more, the height and width of the current block are each less than 128, and the value of the CIIP available flag is 1, the decoding device can parse the CIIP flag from the merge data syntax.
[0335] As another example, based on the condition based on the CIIP availability flag and the condition based on the size of the current block, in addition, the decoding device can obtain the CIIP flag from the bitstream based on the further satisfaction of the condition based on the CU skip flag. Here, the condition based on the CU skip flag is the case where the value of the CU skip flag is 0. In other words, when the product of the height and the width of the current block is 64 or more, the height and the width of the current block are each less than 128, the value of the CIIP availability flag is 1, and the value of the CU skip flag is 0, the decoding device can parse the CIIP flag from the merge data syntax.
[0336] Also, as another example, based on the satisfaction of the condition based on the information regarding the current block and the partitioning mode availability flag, the decoding device can obtain the CIIP flag from the bitstream. Here, the condition based on the information regarding the current block includes the case where the product of the width and the height of the current block is 64 or more and / or the type of the slice including the current block is a B slice. The condition based on the partitioning mode availability flag is the case where the value of the partitioning mode availability flag is 1. In other words, when both the condition based on the height of the current block and the information regarding the current block and the condition based on the partitioning mode availability flag are satisfied, the decoding device can parse the CIIP flag from the merge data syntax.
[0337] When the conditions based on the CIIP availability flag and the conditions based on the size of the current block are not satisfied, the decoding device determines whether the conditions based on the information about the current block and the partitioning mode availability flag are satisfied. Alternatively, when the conditions based on the information about the current block and the partitioning mode availability flag are not satisfied, the decoding device can determine whether the conditions based on the CIIP availability flag and the size of the current block are satisfied. For this purpose, the merge data syntax is configured as shown in Table 9 above.
[0338] When there is no CIIP flag in the bitstream, the decoding device can derive the CIIP flag value as 1 if the value of the general merge flag is 1, the value of the regular merge flag is 0, the value of the merge sub-block flag is 0, the value of the MMVD merge flag is 0, the value of the CIIP availability flag in the SPS is 1, the value of the CU skip flag is 0, the product of the width and height of the current block is 64 or more, the width and height of the current block are each less than 128, the value of the partitioning availability flag in the SPS is 0 or the maximum number of partitioning merge candidates is less than 2 or the slice type is not a B slice. Otherwise, the value of the CIIP flag is derived as 0.
[0339] In the foregoing embodiments, the method is described based on a flowchart in a series of steps or blocks, but the corresponding embodiments are not limited to the order of the steps, and a certain step can occur in a different order or simultaneously with steps different from the foregoing. Also, those skilled in the art can understand that the steps shown in the flowchart are not exclusive, other steps are included, or one or more steps in the flowchart can be deleted without affecting the scope of the embodiments of this document.
[0340] The method according to the embodiments of the foregoing document can be embodied in the form of software, and the encoding device and / or decoding device according to the document can be included in a device that executes video processing, such as a TV, a computer, a smartphone, a set-top box, a display device, etc.
[0341] In this document, when an embodiment is embodied in software, the foregoing method can be embodied by modules (processes, functions, etc.) that perform the foregoing functions. The modules can be stored in a memory and executed by a processor. The memory can be inside or outside the processor and can be connected to the processor by various well-known means. The processor can include an ASIC (application-specific integrated circuit), other chip sets, logic circuits, and / or data processing devices. The memory can include a ROM (read-only memory), a RAM (random access memory), a flash memory, a memory card, a storage medium, and / or other storage devices. That is, the embodiments described in this document can be embodied and executed on a processor, a microprocessor, a controller, or a chip. For example, the functional units shown in each drawing can be embodied and executed on a computer, a processor, a microprocessor, a controller, or a chip. In this case, information for embodiment (for example, information on instructions) or an algorithm can be stored in a digital storage medium.
[0342] In addition, the decoding device and the encoding device to which the example(s) of this document is / are applied can be included in a multimedia broadcast transceiver, a mobile communication terminal, a home cinema video device, a digital cinema video device, a surveillance camera, a video conferencing device, a real-time communication device such as video communication, a mobile streaming device, a storage medium, a camcorder, an on-demand video (VoD) service providing device, an OTT video (Over the top video) device, an Internet streaming service providing device, a three-dimensional (3D) video device, a VR (virtual reality) device, an AR (augmented reality) device, an image phone video device, a transportation means terminal (e.g., a vehicle (including an autonomous driving vehicle) terminal, an airplane terminal, a ship terminal, etc.), and a medical video device, etc., and can be used to process a video signal or a data signal. For example, as an OTT video (Over the top video) device, it can include a game console, a Blu-ray player, an Internet-connected TV, a home theater system, a smartphone, a tablet PC, a DVR (Digital Video Recorder), etc.
[0343] In addition, the processing method to which the example(s) of this document is / are applied can be produced in the form of a program executed by a computer and can be stored in a computer-readable recording medium. Also, multimedia data having a data structure according to the example(s) of this document can be stored in a computer-readable recording medium. The computer-readable recording medium includes all types of storage devices and distributed storage devices in which data that can be read by a computer is stored. The computer-readable recording medium can include, for example, a Blu-ray Disc (BD), a Universal Serial Bus (USB), a ROM, a PROM, an EPROM, an EEPROM, a RAM, a CD-ROM, a magnetic tape, a floppy disk, and an optical data storage device. Also, the computer-readable recording medium includes a medium embodied in the form of a carrier wave (for example, transmission via the Internet). Also, a bitstream generated by an encoding method can be stored in a computer-readable recording medium or can be transmitted via a wired or wireless communication network.
[0344] In addition, the example(s) of this document can be embodied as a computer program product by program code, and the program code can be executed by a computer according to the example(s) of this document. The program code can be stored on a carrier readable by a computer.
[0345] FIG. 14 shows an example of a content streaming system to which the example disclosed in this document can be applied.
[0346] As shown in FIG. 14, the content streaming system to which the example of this document is applied generally includes an encoding server, a streaming server, a web server, a media repository, a user device, and a multimedia input device.
[0347] The encoding server compresses the content input from a multimedia input device such as a smartphone, camera, camcorder, etc. into digital data to generate a bitstream, and serves to transmit this to the streaming server. As another example, when a multimedia input device such as a smartphone, camera, camcorder, etc. directly generates a bitstream, the encoding server can be omitted.
[0348] The bitstream can be generated by an encoding method or a bitstream generation method applied to the embodiments of this document, and the streaming server can temporarily store the bitstream in the process of transmitting or receiving the bitstream.
[0349] The streaming server transmits multimedia data to the user device based on a user request via a web server, and the web server serves as a medium to inform the user of what services are available. When the user requests a desired service from the web server, the web server transmits this to the streaming server, and the streaming server transmits multimedia data to the user. At this time, the content streaming system can include a separate control server. In this case, the control server serves to control commands / responses between each device within the content streaming system.
[0350] The streaming server can receive content from a media repository and / or an encoding server. For example, when it comes to receiving content from the encoding server, the content can be received in real time. In this case, in order to provide a smooth streaming service, the streaming server can store the bitstream for a certain period of time.
[0351] Examples of the user device include a mobile phone, a smart phone, a laptop computer, a digital broadcast terminal, a PDA (personal digital assistants), a PMP (portable multimedia player), a navigation device, a slate PC, a tablet PC, an ultrabook, a wearable device (for example, a smartwatch, a smart glass, an HMD (head mounted display)), a digital TV, a desktop computer, and a digital signage.
[0352] Each server in the content streaming system can be operated as a distributed server, and in this case, the data received by each server can be distributedly processed.
Claims
1. A decoding method performed by a decoding device, obtaining an availability flag for a partitioning mode in which a current block is divided into two partitions for prediction from the bitstream; determining whether to obtain a regular merge flag from the bitstream based on a first condition and a second condition; obtaining the regular merge flag from the bitstream based on the first condition and the second condition being satisfied; generating a predicted sample of the current block by performing inter prediction based on the regular merge flag; generating reconstructed samples based on the predicted samples; the first condition is met based only on a condition related to a height of the current block and a width of the current block; the second condition is satisfied based on a condition based on an availability flag for the partitioning mode, a condition based on a type of a slice including the current block, and a condition based on a size of the current block being satisfied; The decoding method, wherein the condition based on the type of the slice including the current block is satisfied based on the type of the slice including the current block being a B slice.
2. An encoding method performed by an encoding device, deriving a predicted sample of the current block based on inter prediction; generating prediction mode information indicating a prediction mode of the current block; deriving a residual sample based on the prediction sample; generating residual information based on the residual samples; encoding video information including information about the prediction mode and the residual information; The image information includes an availability flag for a partitioning mode in which a current block is divided into two partitions for prediction, the video information includes a regular merge flag based on a first condition and a second condition being satisfied; the first condition is met based only on a condition related to a height of the current block and a width of the current block; the second condition is satisfied based on a condition based on an availability flag for the partitioning mode, a condition based on a type of a slice including the current block, and a condition based on a size of the current block being satisfied; The encoding method, wherein the condition based on the type of a slice including the current block is satisfied based on the type of the slice including the current block being a B slice.
3. In a method of transmitting data for video, obtaining a bitstream for the image, the bitstream being generated by deriving a prediction sample of a current block based on inter prediction, generating information on a prediction mode indicating a prediction mode of the current block, deriving a residual sample based on the prediction sample, generating residual information based on the residual sample, and encoding image information including the information on the prediction mode and the residual information; transmitting the data including the bitstream; The image information includes an availability flag for a partitioning mode in which a current block is divided into two partitions for prediction, the video information includes a regular merge flag based on a first condition and a second condition being satisfied; the first condition is met based only on a condition related to a height of the current block and a width of the current block; the second condition is satisfied based on a condition based on an availability flag for the partitioning mode, a condition based on a type of a slice including the current block, and a condition based on a size of the current block being satisfied; A data transmission method, wherein the condition based on the type of a slice including the current block is satisfied based on the type of the slice including the current block being a B slice.
Citation Information
Patent Citations
Method and apparatus for video coding
WO2020117619A1
System and method for signaling of motion merge modes in video coding
WO2020142448A1
Video signal processing method and device using motion compensation
WO2020149725A1