Motion vector prediction method and apparatus, encoder, and decoder
The method enhances video compression efficiency by predicting motion vectors through a configuration mode-based candidate motion information list in video encoders and decoders, addressing the challenge of high bandwidth and storage requirements in current video coding technologies.
Patent Information
- Application Number
- JP2024217687
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2018-07-18
- Filing Date
- 2024-12-12
- Publication Date
- 2025-04-10
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Current video coding technologies face challenges in efficiently compressing and transmitting video signals due to their large data size, which results in high transmission bandwidth and storage requirements.
The proposed solution involves a method for motion vector prediction in video encoders and decoders, where a configuration mode is determined for a candidate motion information list. This list can be either block-based or sub-block-based, depending on an identifier, and is used to predict the current coding block based on optimal motion information.
This approach reduces the transmission cost of optimal candidate motion information and improves the efficiency of video compression by effectively predicting motion vectors, thereby reducing the bandwidth and storage needs.
Smart Images

Figure 2025060684000001_ABST
Abstract
Description
[Technical field]
[0001] The present application relates to the field of video coding technology, and in particular to a motion vector prediction method and apparatus, and corresponding encoder and decoder. [Background technology]
[0002] With the development of information technology, video services such as high-definition television, web conferencing, IPTV, and 3D television develop rapidly. Video signals become the most important way of obtaining information in people's daily life due to advantages such as intuitiveness and high efficiency. Video signals contain a large amount of data, and therefore occupy a large amount of transmission bandwidth and storage space. In order to effectively transmit and store video signals, the video signals need to be compressed and encoded. Video compression technology becomes an increasingly indispensable key technology in the field of video applications. Summary of the Invention [Means for solving the problem]
[0003] DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0011] The present invention relates to a video encoder, a video decoder, and a method for implementing the same.
[0004] According to a first aspect, the present invention relates to a decoding method or a motion vector prediction method, the method includes: obtaining a configuration mode of a candidate motion information list including optimal candidate motion information of a current coding block; obtaining an index of optimal candidate motion information in the candidate motion information list, where the configuration mode of the candidate motion information list is a mode of configuring a block-based candidate motion information list or a mode of configuring a sub-block-based candidate motion information list; configuring the candidate motion information list in the configuration mode; determining optimal motion information from the configured candidate motion information list based on the index; and predicting the current coding block based on the optimal motion information.
[0005] It should be understood that in the current technology, the current coding block can be partitioned into smaller sub-blocks. For example, the current coding block can be partitioned through repetition using a quad-tree (QT) partition, a binary-tree (BT) partition, or a triple-tree (TT) partition, or any combination thereof. In other words, one coding block can be divided into smaller sub-blocks.
[0006] In this method, a candidate motion information list of a current block (in some cases, due to differences in language conventions, the current coding block may refer to a current picture block, a current encoding block, a current decoding block, a current block to be encoded, a current block to be decoded, etc., and the name should not be any limitation in the present invention) is classified. The candidate motion information is classified into candidate motion information obtained through block-based prediction and candidate motion information obtained through sub-block-based prediction. A block-based candidate motion information list and a sub-block-based candidate motion information list are constructed. This can effectively reduce the transmission cost of the optimal candidate motion information.
[0007] According to the first aspect, in a possible implementation process, obtaining a configuration mode of a candidate motion information list including the optimal candidate motion information of a current block includes obtaining an identifier used to determine a candidate motion information list, where when the inter-prediction mode used for the current block is a merge mode and the identifier is a first feature value, the configuration mode of the candidate motion information list is a mode of configuring a block-based candidate motion information list, or when the identifier is a second feature value, the configuration mode of the candidate motion information list is a mode of configuring a sub-block-based candidate motion information list. It should be understood that the first feature value and the second feature value are names used to represent two values and do not make any limitation.
[0008] Optionally, the first feature value may be 0 or 1, and the second feature value may be 1 or 0. Optionally, the identifier may be represented as, for example, list-idx. However, this is not limited. Optionally, the candidate motion information list configured in the block-based mode may be represented as list0 (or list1), and the candidate motion information list configured in the sub-block-based mode may be represented as list1 (or list0). It should be understood that the specific values of the feature values, or the specific representation symbols of the identifiers and lists are not limited and are not necessarily exhaustively described in the present invention.
[0009] According to the first aspect, in a possible implementation process, the block-based candidate motion information list includes a candidate motion information list that is configured in a merge mode defined according to HEVC standard or the advanced version of HEVC standard. For example, the motion information of the spatially or temporally adjacent coding block of the current coding block is added into the candidate motion information list according to a preset rule. For some possible configuration modes, please refer to the related description in embodiment S11.1.
[0010] According to the first aspect, in a possible implementation process, the candidate motion information in the block-based candidate motion information list includes at least one of the motion information of the spatially adjacent coded blocks of the current block or the motion information of the temporally adjacent coded blocks of the current block. All the candidate motion information in the candidate motion information list may be the motion information of the spatially or temporally adjacent coded blocks of the current block. Alternatively, some of the candidate motion information may be the motion information of the spatially or temporally adjacent coded blocks of the current block, and some of the candidate motion information may be the motion information obtained in another manner.
[0011] According to the first aspect, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list that is configured with at least one sub-block-based merge mode of affine model merge, complex merge, or ATMVP. All the candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of the three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0012] According to the first aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0013] According to the first aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0014] According to the first aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first determine a collocated reference picture, then divide a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtain motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scale the motion information, convert the motion information into the motion information of each current coding subunit, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0015] According to the first embodiment, in a possible implementation process, the width of the current block is equal to or greater than a threshold value, and / or the height of the current block is equal to or greater than a threshold value. The threshold value may be 4, 8, or 16, but is not limited thereto.
[0016] According to the first aspect, in a possible implementation process, if the optimal motion information is the motion information in the block-based candidate motion information list, the current block is predicted based on the optimal motion information.
[0017] According to the first embodiment, in a possible implementation process, when the optimal motion information is the motion information in the sub-block-based candidate motion information list, at least the following three cases are included:
[0018] Case 1: When the optimal motion information determined in S23 is obtained in an affine mode (including at least an affine model merge mode or a complex merge mode), motion information corresponding to a sub-block of a current block is derived based on the optimal motion information, and the sub-block of the current block is predicted. The current block may include multiple sub-blocks, and the sub-block of the current block may be any one of the multiple sub-blocks. In a possible implementation process, motion information corresponding to each sub-block of the current block is derived based on the optimal motion information, and each sub-block of the current block is predicted correspondingly.
[0019] Case 2: When the optimal motion information determined in S23 is obtained in ATMVP mode, the sub-block of the current block is predicted based on the optimal motion information. In a possible implementation process, the optimal candidate motion information may be a combination of motion information, including the motion information corresponding to each sub-block of the current block, and each sub-block of the current block is predicted correspondingly.
[0020] Case 3: When the optimal motion information determined in S23 is obtained in ATMVP mode through display, the optimal motion information is obtained based on the corresponding display, and the sub-blocks of the current block are predicted based on the optimal motion information. In a possible implementation process, the optimal candidate motion information can be obtained based on display information. The motion information corresponding to each sub-block of the current block can be obtained in ATMVP mode based on display information, and each sub-block of the current block is predicted correspondingly.
[0021] According to a second aspect, the present invention relates to a decoding method or a motion vector prediction method, the method includes: obtaining an identifier used to determine a candidate motion information list including optimal candidate motion information of a current block; obtaining an index of optimal candidate motion information in the candidate motion information list, where an inter prediction mode used for the current block is a merge mode; configuring the candidate motion information list based on the identifier, where when the identifier is a first feature value, the candidate motion information list is a block-based candidate motion information list, or when the identifier is a second feature value, the candidate motion information list is a sub-block-based candidate motion information list; determining optimal motion information from the configured candidate motion information list based on the index; and predicting the current block based on the optimal motion information.
[0022] According to the second aspect, in a possible implementation process, the block-based candidate motion information list includes a candidate motion information list that is configured in a merge mode defined according to the HEVC standard or the advanced version of the HEVC standard. For example, the motion information of the spatially or temporally adjacent coding block of the current coding block is added into the candidate motion information list according to a preset rule. For some possible configuration modes, please refer to the related description in embodiment S11.1.
[0023] According to the second aspect, in a possible implementation process, the candidate motion information in the block-based candidate motion information list includes at least one of the motion information of the spatially adjacent coded blocks of the current block or the motion information of the temporally adjacent coded blocks of the current block. All the candidate motion information in the candidate motion information list may be the motion information of the spatially or temporally adjacent coded blocks of the current block. Alternatively, some of the candidate motion information may be the motion information of the spatially or temporally adjacent coded blocks of the current block, and some of the candidate motion information may be the motion information obtained in another manner.
[0024] According to the second aspect, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list that is configured with at least one sub-block-based merge mode of affine model merge, complex merge, or ATMVP. All the candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of the three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0025] According to the second aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0026] According to the second aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a pre-configured rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0027] According to the second aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first determine a collocated reference picture, then divide a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtain motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scale the motion information, convert the motion information into the motion information of each current coding subunit, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0028] According to the second embodiment, in a possible implementation process, the width of the current block is equal to or greater than a threshold value, and / or the height of the current block is equal to or greater than a threshold value. The threshold value may be 4, 8, or 16, but is not limited thereto.
[0029] According to a third aspect, the present invention relates to a motion vector prediction method, the method includes: when a size of a current block meets a preset sample quantity, an identifier used to determine a candidate motion information list including optimal candidate motion information of a current block, and an index of optimal candidate motion information in the candidate motion information list, where an inter prediction mode used for the current block is a merge mode; configuring the candidate motion information list based on the identifier, where when the identifier is a first feature value, configuring a block-based candidate motion information list, or when the identifier is a second feature value, configuring a sub-block-based candidate motion information list; determining optimal motion information from the configured candidate motion information list based on the index; and predicting the current block based on the optimal motion information.
[0030] According to a third aspect, a possible implementation process includes: when the size of the current block does not meet a preset sample quantity, constructing a block-based candidate motion information list, and obtaining an index of an optimal candidate motion information in the candidate motion information list, where the inter prediction mode used for the current block is merge mode; determining optimal motion information from the constructed candidate motion information list based on the obtained index; and predicting the current block based on the optimal motion information.
[0031] The inventive concept of this solution is as follows: first determine whether the current block satisfies a preset condition, and if the current block satisfies the preset condition, obtain an identifier that can indicate a candidate motion information list including optimal candidate motion information of the current block, and construct a block-based candidate motion information list or a sub-block-based candidate motion information list based on the identifier, or if the current block does not satisfy the preset condition, only construct a block-based candidate motion information list, and determine optimal candidate motion information from the constructed candidate motion information list based on the obtained motion information index, and predict the current block.
[0032] According to a third embodiment, in a possible implementation process, whether the current block satisfies the preset condition includes, but is not limited to, whether the size of the current block meets a preset sample quantity.
[0033] According to a third aspect, in a possible implementation process, the size of the current block meeting the pre-set sample quantity includes the width of the current block being greater than or equal to a threshold value and / or the height of the current block being greater than or equal to a threshold value.
[0034] Optionally, when the size of the current block meets the preset sample quantity, the width of the current block is equal to or greater than a threshold, when the size of the current block does not meet the preset sample quantity, the width of the current block is less than a threshold, when the size of the current block meets the preset sample quantity, the height of the current block is equal to or greater than a threshold, when the size of the current block does not meet the preset sample quantity, when the height of the current block is less than a threshold, when the size of the current block meets the preset sample quantity, the width of the current block is equal to or greater than a threshold or the height of the current block is equal to or greater than another threshold, when the size of the current block does not meet the preset sample quantity, when the width of the current block is less than a threshold and the height of the current block is less than another threshold, or when the size of the current block meets the preset sample quantity, when the width of the current block is equal to or greater than a threshold and the height of the current block is equal to or greater than another threshold, when the size of the current block does not meet the preset sample quantity, when the width of the current block is less than a threshold or the height of the current block is less than another threshold. The threshold may be, but is not limited to, 4, 8, or 16. It should be understood that this logic is merely an example and does not constitute any limitation. In addition, the relationship between width and height is also not limited in the present invention.
[0035] According to the third aspect, in a possible implementation process, the block-based candidate motion information list includes a candidate motion information list that is configured in a merge mode defined according to HEVC standard or an advanced version of HEVC standard. For example, the motion information of the spatially or temporally adjacent coding block of the current coding block is added into the candidate motion information list according to a preset rule. For some possible configuration modes, please refer to the related description in embodiment S11.1.
[0036] According to the third aspect, in a possible implementation process, all the candidate motion information in the obtained block-based candidate motion information list may be the motion information of the spatially or temporally adjacent coded blocks of the current block. Alternatively, some of the candidate motion information may be the motion information of the spatially or temporally adjacent coded blocks of the current block, and some of the candidate motion information may be the motion information obtained in another manner.
[0037] According to the third aspect, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list that is configured with at least one sub-block-based merge mode of affine model merge, complex merge, or ATMVP. All the candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of the three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0038] According to the third aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0039] According to the third aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0040] According to the third aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, firstly determining a collocated reference picture, then dividing a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtaining motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scaling the motion information, converting the motion information into the motion information of each current coding subunit, and inserting the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0041] The above method can be performed by a motion vector prediction apparatus or device. Optionally, the present invention provides an apparatus according to the first, second and third aspects in the fourth, fifth and sixth aspects.
[0042] According to a fourth aspect, the present invention relates to a decoding device or a motion vector prediction device, which includes: an acquisition module configured to acquire a configuration mode of a candidate motion information list including optimal candidate motion information of a current block, and acquire an index of the optimal candidate motion information in the candidate motion information list, where the configuration mode of the candidate motion information list is a mode of configuring a block-based candidate motion information list or a mode of configuring a sub-block-based candidate motion information list; a configuration module configured to configure the candidate motion information list in the configuration mode; a decision module configured to determine optimal motion information from the configured candidate motion information list based on the index; and a prediction module configured to predict the current block based on the optimal motion information.
[0043] According to a fourth aspect, in a possible implementation process, the acquisition module is particularly configured to acquire an identifier used to determine a candidate motion information list, where when the inter prediction mode used for the current block is a merge mode and the identifier is a first feature value, the configuration mode of the candidate motion information list is a mode of configuring a block-based candidate motion information list, or when the identifier is a second feature value, the configuration mode of the candidate motion information list is a mode of configuring a sub-block-based candidate motion information list.
[0044] Optionally, the first feature value may be 0 or 1, and the second feature value may be 1 or 0. Optionally, the identifier may be represented as, for example, list-idx. However, this is not limited. Optionally, the candidate motion information list configured in the block-based mode may be represented as list0 (or list1), and the candidate motion information list configured in the sub-block-based mode may be represented as list1 (or list0). It should be understood that the specific values of the feature values, or the specific representation symbols of the identifiers and lists are not limited and are not necessarily exhaustively described in the present invention.
[0045] According to the fourth aspect, in a possible implementation process, the block-based candidate motion information list includes a candidate motion information list that is configured in a merge mode defined according to HEVC standard or an advanced version of HEVC standard. For example, the motion information of the spatially or temporally adjacent coding block of the current coding block is added into the candidate motion information list according to a preset rule. For some possible configuration modes, please refer to the related description in embodiment S11.1.
[0046] According to a fourth aspect, in a possible implementation process, the candidate motion information in the block-based candidate motion information list includes at least one of the motion information of the spatially adjacent coded blocks of the current block or the motion information of the temporally adjacent coded blocks of the current block. All the candidate motion information in the candidate motion information list may be the motion information of the spatially or temporally adjacent coded blocks of the current block. Alternatively, some of the candidate motion information may be the motion information of the spatially or temporally adjacent coded blocks of the current block, and some of the candidate motion information may be the motion information obtained in another manner.
[0047] According to the fourth aspect, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list that is configured with at least one sub-block-based merge mode of affine model merge, complex merge, or ATMVP. All the candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of the three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0048] According to the fourth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0049] According to the fourth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0050] According to the fourth aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first determine a collocated reference picture, then divide a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtain motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scale the motion information, convert the motion information into the motion information of each current coding subunit, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0051] According to a fourth embodiment, in a possible implementation process, the width of the current block is equal to or greater than a threshold value, and / or the height of the current block is equal to or greater than a threshold value. The threshold value may be 4, 8, or 16, but is not limited thereto.
[0052] According to a fifth aspect, the present invention relates to a decoding device or a motion vector prediction device. The device includes: an acquisition module configured to acquire an identifier used to determine a candidate motion information list including optimal candidate motion information of a current block, and to acquire an index of optimal candidate motion information in the candidate motion information list, where an inter prediction mode used for the current block is a merge mode; a configuration module configured to configure the candidate motion information list based on the identifier, where the candidate motion information list is a block-based candidate motion information list when the identifier is a first feature value, or the candidate motion information list is a sub-block-based candidate motion information list when the identifier is a second feature value; a decision module configured to determine optimal motion information from the configured candidate motion information list based on the index; and a prediction module configured to predict the current block based on the optimal motion information.
[0053] According to the fifth aspect, in a possible implementation process, the block-based candidate motion information list includes a candidate motion information list configured in a merge mode defined according to the HEVC standard or the advanced version of the HEVC standard. For example, the motion information of the spatially or temporally adjacent coding block of the current coding block is added into the candidate motion information list according to a preset rule. For some possible configuration modes, please refer to the related description in embodiment S11.1.
[0054] According to the fifth aspect, in a possible implementation process, the candidate motion information in the block-based candidate motion information list includes at least one of the motion information of the spatially adjacent coded blocks of the current block or the motion information of the temporally adjacent coded blocks of the current block. All the candidate motion information in the candidate motion information list may be the motion information of the spatially or temporally adjacent coded blocks of the current block. Alternatively, some of the candidate motion information may be the motion information of the spatially or temporally adjacent coded blocks of the current block, and some of the candidate motion information may be the motion information obtained in another manner.
[0055] According to the fifth aspect, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list that is configured with at least one sub-block-based merge mode of affine model merge, complex merge, or ATMVP. All the candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of the three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0056] According to the fifth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0057] According to the fifth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0058] According to the fifth aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first determine a collocated reference picture, then divide a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtain motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scale the motion information, convert the motion information into the motion information of each current coding subunit, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0059] According to a fifth embodiment, in a possible implementation process, the width of the current block is equal to or greater than a threshold value, and / or the height of the current block is equal to or greater than a threshold value. The threshold value may be 4, 8, or 16, but is not limited thereto.
[0060] According to a sixth aspect, the present invention relates to a decoding device or a motion vector prediction device. The device includes: an acquisition module configured to acquire an identifier of a candidate motion information list including optimal candidate motion information of a current block when the size of the current block meets a preset number of samples, and to acquire an index of the optimal candidate motion information in the candidate motion information list, where an inter prediction mode used for the current block is a merge mode; a configuration module configured to configure a candidate motion information list based on the identifier, the configuration module configuring a block-based candidate motion information list when the identifier is a first feature value, or a sub-block-based candidate motion information list when the identifier is a second feature value; a determination module configured to determine optimal motion information from the configured candidate motion information list based on the index; and a prediction module configured to predict the current block based on the optimal motion information.
[0061] According to a sixth aspect, in a possible implementation process, the configuration module is further specifically configured to configure a block-based candidate motion information list when the size of the current block does not meet a pre-set sample quantity, and wherein the inter-prediction mode used for the current block is a merge mode.
[0062] According to a sixth embodiment, in a possible implementation process, whether the current block satisfies a preset condition includes, but is not limited to, whether the size of the current block meets a preset sample quantity.
[0063] According to a sixth aspect, in a possible implementation process, the size of the current block meeting a pre-set sample quantity includes the width of the current block being greater than or equal to a threshold value and / or the height of the current block being greater than or equal to a threshold value.
[0064] Optionally, when the size of the current block meets the preset sample quantity, the width of the current block is equal to or greater than a threshold, when the size of the current block does not meet the preset sample quantity, the width of the current block is less than a threshold, when the size of the current block meets the preset sample quantity, the height of the current block is equal to or greater than a threshold, when the size of the current block does not meet the preset sample quantity, when the height of the current block is less than a threshold, when the size of the current block meets the preset sample quantity, the width of the current block is equal to or greater than a threshold or the height of the current block is equal to or greater than another threshold, when the size of the current block does not meet the preset sample quantity, when the width of the current block is less than a threshold and the height of the current block is less than another threshold, or when the size of the current block meets the preset sample quantity, when the width of the current block is equal to or greater than a threshold and the height of the current block is equal to or greater than another threshold, when the size of the current block does not meet the preset sample quantity, when the width of the current block is less than a threshold or the height of the current block is less than another threshold. The threshold may be, but is not limited to, 4, 8, or 16. It should be understood that this logic is merely an example and does not constitute any limitation. In addition, the relationship between width and height is also not limited in the present invention.
[0065] According to the sixth aspect, in a possible implementation process, the block-based candidate motion information list includes a candidate motion information list configured in a merge mode defined according to the HEVC standard or the advanced version of the HEVC standard. For example, the motion information of the spatially or temporally adjacent coding block of the current coding block is added into the candidate motion information list according to a preset rule. For some possible configuration modes, please refer to the related description in embodiment S11.1.
[0066] According to the sixth aspect, in a possible implementation process, all candidate motion information in the obtained block-based candidate motion information list can be the motion information of the spatially or temporally adjacent coded blocks of the current block. Alternatively, some of the candidate motion information can be the motion information of the spatially or temporally adjacent coded blocks of the current block, and some of the candidate motion information can be the motion information obtained in another manner.
[0067] According to the sixth embodiment, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list that is configured with at least one sub-block-based merge mode of affine model merge, complex merge, or ATMVP. All the candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of the three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0068] According to the sixth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0069] According to the sixth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a pre-configured rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0070] According to the sixth aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first determine a collocated reference picture, then divide a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtain motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scale the motion information, convert the motion information into the motion information of each current coding subunit, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0071] According to a seventh aspect, the present invention relates to a decoding method or a motion vector prediction method, the method includes: parsing a bitstream to obtain a syntax element, where the syntax element includes at least an index of optimal candidate motion information for a current block; determining based on the syntax element that a first list or a second list should be constructed for a current picture block, where the first list is a block-based candidate motion information list and the second list is a sub-block-based candidate motion information list; determining optimal motion information from the first list or the second list based on the index; and predicting the current block based on the optimal motion information.
[0072] According to the seventh aspect, in a possible implementation process, the block-based candidate motion information list is a candidate motion information list configured in a conventional merge mode (which may also be expressed as general_merge or regular_merge in some scenarios).
[0073] According to the seventh aspect, in a possible implementation process, the conventional merge mode includes a mode defined according to the HEVC standard or an advanced version of the HEVC standard. In particular, the block-based candidate motion information list includes a candidate motion information list that is configured with a conventional merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
[0074] According to a seventh aspect, in a possible implementation process, the candidate motion information in the first list includes one or more of motion information of a spatially adjacent block to the above and to the left of the current picture block, motion information of a spatially adjacent block to the left of the current picture block, motion information of a spatially adjacent block to the below and to the left of the current picture block, motion information of a spatially adjacent block to the above and to the right of the current picture block, or motion information of a spatially adjacent block to the right of the current picture block.
[0075] According to a seventh aspect, in a possible implementation process, the sub-block-based candidate motion information list is a candidate motion information list configured in a sub-block-based merge (merge_subblock) mode.
[0076] According to the seventh aspect, in a possible implementation process, the sub-block based merge mode includes at least one of affine model merge, complex merge, or ATMVP. In particular, the sub-block based candidate motion information list includes a candidate motion information list configured with at least one sub-block based merge mode of affine model merge, complex merge, or ATMVP.
[0077] According to the seventh aspect, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list composed only of the sub-block-based merge mode of ATMVP.
[0078] According to the seventh embodiment, in a possible implementation process, all the candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list can further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0079] According to the seventh aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0080] According to the seventh aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a pre-configured rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0081] According to the seventh aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, firstly determining a collocated reference picture, then dividing a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtaining motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scaling the motion information, converting the motion information into the motion information of each current coding subunit, and inserting the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0082] According to a seventh aspect, in a possible implementation process, the syntax element includes a list index, and determining based on the syntax element whether a first list or a second list should be constructed for a current picture block includes obtaining a candidate motion information list index, where when the list index is a first feature value, it indicates that a first list should be constructed for the current picture block, and when the list index is a second feature value, it indicates that a second list should be constructed for the current picture block.
[0083] According to a seventh aspect, in a possible implementation process, the syntax element further includes display information used to indicate a conventional merging mode to be used for the current block, or display information used to indicate a sub-block based merging mode to be used for the current block.
[0084] According to a seventh aspect, in a possible implementation process, the syntax element further includes display information used to indicate that a block-based candidate motion information list is used for the current block, or display information used to indicate that a sub-block-based candidate motion information list is used for the current block.
[0085] According to the seventh aspect, in a possible implementation process, the first feature value may be 0 or 1, and the second feature value may be 1 or 0. Optionally, the identifier may be represented as, for example, list-idx. However, this is not limited. Optionally, the candidate motion information list configured in block-based mode may be represented as list0 (or list1), and the candidate motion information list configured in sub-block-based mode may be represented as list1 (or list0). It should be understood that the specific value of the feature value, or the specific representation symbol of the identifier and list is not limited and is not necessarily exhaustively described in the present invention.
[0086] According to the seventh embodiment, in a possible implementation process, the width of the current block is equal to or greater than a threshold value, and / or the height of the current block is equal to or greater than a threshold value. The threshold value may be 4, 8, or 16, but is not limited thereto.
[0087] According to the seventh aspect, in a possible implementation process, if the optimal motion information is the motion information in the block-based candidate motion information list, the current block is predicted based on the optimal motion information.
[0088] According to the seventh aspect, in a possible implementation process, when the optimal motion information is the motion information in the sub-block-based candidate motion information list, at least the following three cases are included:
[0089] Case 1: When the optimal motion information determined in S23 is obtained in an affine mode (including at least an affine model merge mode or a complex merge mode), motion information corresponding to a sub-block of a current block is derived based on the optimal motion information, and the sub-block of the current block is predicted. The current block may include multiple sub-blocks, and the sub-block of the current block may be any one of the multiple sub-blocks. In a possible implementation process, motion information corresponding to each sub-block of the current block is derived based on the optimal motion information, and each sub-block of the current block is predicted correspondingly.
[0090] Case 2: When the optimal motion information determined in S23 is obtained in ATMVP mode, the sub-block of the current block is predicted based on the optimal motion information. In a possible implementation process, the optimal candidate motion information may be a combination of motion information, including the motion information corresponding to each sub-block of the current block, and each sub-block of the current block is predicted correspondingly.
[0091] Case 3: When the optimal motion information determined in S23 is obtained in ATMVP mode through display, the optimal motion information is obtained based on the corresponding display, and the sub-blocks of the current block are predicted based on the optimal motion information. In a possible implementation process, the optimal candidate motion information can be obtained based on display information. The motion information corresponding to each sub-block of the current block can be obtained in ATMVP mode based on display information, and each sub-block of the current block is predicted correspondingly.
[0092] According to an eighth aspect, the present invention relates to a decoding device or a motion vector prediction device, which includes: an acquisition module configured to parse a bitstream to acquire a syntax element, where the syntax element includes at least an index of optimal candidate motion information of a current block; a configuration module configured to determine based on the syntax element that a first list or a second list should be configured for a current picture block, where the first list is a block-based candidate motion information list and the second list is a sub-block-based candidate motion information list; a determination module configured to determine optimal motion information from the first list or the second list based on the index; and a prediction module configured to predict the current block based on the optimal motion information.
[0093] According to the eighth aspect, in a possible implementation process, the block-based candidate motion information list is a candidate motion information list configured in a conventional merge mode (which may also be expressed as general_merge or regular_merge in some scenarios).
[0094] According to an eighth aspect, in a possible implementation process, the conventional merge mode includes a mode defined according to the HEVC standard or an advanced version of the HEVC standard. In particular, the block-based candidate motion information list includes a candidate motion information list that is configured with a conventional merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
[0095] According to an eighth aspect, in a possible implementation process, the candidate motion information in the first list includes one or more of motion information of a spatially adjacent block to the above and to the left of the current picture block, motion information of a spatially adjacent block to the left of the current picture block, motion information of a spatially adjacent block to the below and to the left of the current picture block, motion information of a spatially adjacent block to the above and to the right of the current picture block, or motion information of a spatially adjacent block to the right of the current picture block.
[0096] According to an eighth aspect, in a possible implementation process, the subblock-based candidate motion information list is a candidate motion information list configured in a subblock-based merge (merge_subblock) mode.
[0097] According to an eighth aspect, in a possible implementation process, the sub-block based merge mode includes at least one of affine model merge, complex merge, or ATMVP. In particular, the sub-block based candidate motion information list includes a candidate motion information list configured with at least one sub-block based merge mode of affine model merge, complex merge, or ATMVP.
[0098] According to an eighth aspect, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list composed only of the sub-block-based merge mode of ATMVP.
[0099] According to the eighth embodiment, in a possible implementation process, all candidate motion information in the sub-block-based candidate motion information list can be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes can be any combination of three modes: affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list can further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0100] According to the eighth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0101] According to the eighth aspect, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a pre-configured rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and excluding the repeated unqualified information and inserting the motion information into the candidate motion information list. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0102] According to the eighth aspect, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, firstly determining a collocated reference picture, then dividing a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtaining motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scaling the motion information, converting the motion information into the motion information of each current coding subunit, and inserting the motion information corresponding to the available location block into the candidate motion information list successively after checking availability and removing repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0103] According to an eighth aspect, in a possible implementation process, the syntax element includes a list index, and the construction module is specifically configured to obtain a candidate motion information list index, where when the list index is a first feature value, it indicates that a first list should be constructed for the current picture block, or when the list index is a second feature value, it indicates that a second list should be constructed for the current picture block.
[0104] According to an eighth aspect, in a possible implementation process, the syntax element further includes display information used to indicate a conventional merging mode to be used for the current block, or display information used to indicate a sub-block based merging mode to be used for the current block.
[0105] According to an eighth aspect, in a possible implementation process, the syntax element further includes display information used to indicate that a block-based candidate motion information list is used for the current block, or display information used to indicate that a sub-block-based candidate motion information list is used for the current block.
[0106] According to the eighth aspect, in a possible implementation process, the first feature value may be 0 or 1, and the second feature value may be 1 or 0. Optionally, the identifier may be represented as, for example, list-idx. However, this is not limited. Optionally, the candidate motion information list configured in block-based mode may be represented as list0 (or list1), and the candidate motion information list configured in sub-block-based mode may be represented as list1 (or list0). It should be understood that the specific value of the feature value, or the specific representation symbol of the identifier and list is not limited and is not necessarily exhaustively described in the present invention.
[0107] According to the eighth embodiment, in a possible implementation process, the width of the current block is equal to or greater than a threshold value, and / or the height of the current block is equal to or greater than a threshold value. The threshold value may be 4, 8, or 16, but is not limited thereto.
[0108] According to a ninth aspect, the present invention relates to an encoding method or a motion vector prediction method, the method including: configuring a first list, where the first list is a block-based candidate motion information list; configuring a second list, where the second list is a sub-block-based candidate motion information list; determining an optimal candidate motion information from the first candidate motion information list and the second candidate motion information list; and predicting a current block based on the optimal motion information.
[0109] According to a ninth aspect, in a possible implementation process, the method further includes obtaining an identifier used to determine a candidate motion information list including optimal candidate motion information for the current block, and obtaining an index of the optimal candidate motion information in the candidate motion information list, where when the inter prediction mode used for the current block is a merge mode and the identifier is a first feature value, the candidate motion information list is the first list, or when the identifier is a second feature value, the candidate motion information list is the second list, and encoding the identifier and the index into a bitstream.
[0110] According to a tenth aspect, the present invention relates to an encoding method or a motion vector prediction method, the method includes: obtaining an identifier used to determine a candidate motion information list including optimal candidate motion information for a current block; obtaining an index of the optimal candidate motion information in the candidate motion information list, where an inter prediction mode used for the current block is a merge mode and when the identifier is a first feature value, the candidate motion information list is a block-based candidate motion information list, or when the identifier is a second feature value, the candidate motion information list is a sub-block-based candidate motion information list; and encoding the identifier and the index into a bitstream.
[0111] According to an eleventh aspect, the present invention relates to an encoding method or a motion vector prediction method, the method includes: when a size of a current block meets a preset sample quantity, configuring a first list and a second list, where the first list is a block-based candidate motion information list, the second list is a sub-block-based candidate motion information list, and an inter prediction mode used for the current block is a merge mode, determining an optimal candidate motion information from the first list and the second list, and predicting the current block according to the optimal motion information.
[0112] According to an eleventh aspect, in a possible implementation process, the method further includes: when the size of the current block meets a preset sample quantity, constructing a first list, where the first list is a block-based candidate motion information list and the inter prediction mode used for the current block is merge mode, determining an optimal candidate motion information from the first list, and predicting the current block based on the optimal motion information.
[0113] According to a twelfth aspect, the present invention relates to an encoding device or a motion vector prediction device, which includes a configuration module configured to configure a first list and a second list, where the first list is a block-based candidate motion information list and the second list is a sub-block-based candidate motion information list, a determination module configured to determine an optimal candidate motion information from the first candidate motion information list and the second candidate motion information list, and a prediction module configured to predict a current block based on the optimal motion information.
[0114] According to a twelfth aspect, in a possible implementation process, the apparatus further includes an acquisition module configured to acquire an identifier used to determine a candidate motion information list including optimal candidate motion information for a current block, and to acquire an index of the optimal candidate motion information in the candidate motion information list, where the inter prediction mode used for the current block is a merge mode and the candidate motion information list is the first list when the identifier is a first feature value, or the candidate motion information list is the second list when the identifier is a second feature value, and an encoding module configured to encode the identifier and the index into a bitstream.
[0115] According to a thirteenth aspect, the present invention relates to an encoding device or a motion vector prediction device. The device includes: an acquisition module configured to acquire an identifier used to determine a candidate motion information list including optimal candidate motion information of a current block, and to acquire an index of the optimal candidate motion information in the candidate motion information list, where the inter-prediction mode used for the current block is a merge mode, and when the identifier is a first feature value, the candidate motion information list is a block-based candidate motion information list, or when the identifier is a second feature value, the candidate motion information list is a sub-block-based candidate motion information list; and an encoding module configured to encode the identifier and the index into a bitstream.
[0116] According to a fourteenth aspect, the present invention relates to an encoding device or a motion vector prediction device, which includes: a configuration module configured to configure a first list and a second list when a size of a current block meets a preset sample quantity, where the first list is a block-based candidate motion information list, the second list is a sub-block-based candidate motion information list, and an inter prediction mode used for the current block is a merge mode; a decision module configured to determine an optimal candidate motion information from the first list and the second list; and a prediction module configured to predict the current block based on the optimal motion information.
[0117] According to a 14th aspect, in a possible implementation process, the configuration module is further configured to configure a first list when the size of the current block meets a pre-set sample quantity, where the first list is a block-based candidate motion information list and the inter-prediction mode used for the current block is a merge mode.
[0118] According to the ninth to fourteenth aspects (including any one of the ninth, tenth, eleventh, twelfth, thirteenth, and fourteenth aspects), in a possible implementation process, the first feature value may be 0 or 1, and the second feature value may be 1 or 0. Optionally, the identifier may be represented as, for example, list-idx. However, this is not limited. Optionally, the candidate motion information list configured in the block-based mode may be represented as list0 (or list1), and the candidate motion information list configured in the sub-block-based mode may be represented as list1 (or list0). It should be understood that the specific values of the feature values, or the specific representation symbols of the identifiers and lists are not limited and are not necessarily exhaustively described in the present invention.
[0119] According to the ninth to fourteenth aspects, in a possible implementation process, the block-based candidate motion information list includes a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard. For example, the motion information of the spatially or temporally adjacent coding block of the current coding block is added into the candidate motion information list according to a preset rule. For some possible configuration modes, please refer to the related description in embodiment S11.1.
[0120] According to the ninth to fourteenth aspects, in a possible implementation process, the candidate motion information in the block-based candidate motion information list includes at least one of the motion information of the spatially adjacent coded blocks of the current block or the motion information of the temporally adjacent coded blocks of the current block. All the candidate motion information in the candidate motion information list may be the motion information of the spatially or temporally adjacent coded blocks of the current block. Alternatively, some of the candidate motion information may be the motion information of the spatially or temporally adjacent coded blocks of the current block, and some of the candidate motion information may be the motion information obtained in another manner.
[0121] According to the ninth to fourteenth aspects, in a possible implementation process, the sub-block-based candidate motion information list includes a candidate motion information list configured with at least one sub-block-based merge mode among affine model merge, complex merge, or ATMVP. All the candidate motion information in the sub-block-based candidate motion information list may be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes may be any combination of the three modes, affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another sub-block-based mode. This is not enumerated or described in detail in the present invention.
[0122] According to the ninth to fourteenth aspects, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a motion model-based Affine model merge (AMM) mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first find an affine coding block, obtain the motion information of the control points of the affine coding block, derive the motion information of the upper-left vertex and the motion information of the upper-right vertex of the current coding block according to an affine transformation model, and insert the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.1.
[0123] According to the ninth to fourteenth aspects, in a possible implementation process, the sub-block-based candidate motion information list may be configured in a control point-based complex merge mode. The motion information of the spatially adjacent coding blocks of the current coding block is added into the candidate motion information list according to a pre-configured rule. A specific implementation method is, for example, but not limited to, obtaining the motion information of each control point through derivation, synthesizing the motion information of the control points to obtain non-translational (affine model-based) motion information, traversing these models obtained by synthesizing the motion information of the control points in a pre-configured sequence, checking the availability of the candidate motion information in the valid model and removing the repeated items, and inserting the motion information into the candidate motion information list while excluding the repeated unqualified information. For some possible configuration modes, please refer to the related description in embodiment S12.2.
[0124] According to the ninth to fourteenth aspects, in a possible implementation process, the subblock-based candidate motion information list may be configured in an Advanced temporal motion vector prediction (ATMVP) mode. Specifically, ATMVP candidate motion information is added into the candidate motion information list according to a preset rule. A specific implementation method is, for example, but not limited to, first determining a collocated reference picture, then dividing a current coding unit (current block) into coding subunits (coding subblocks) each having a size of M×N, obtaining motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture, scaling the motion information, converting the motion information into the motion information of each current coding subunit, and inserting the motion information corresponding to the available location block into the candidate motion information list successively after checking the availability and removing the repeated items. For some possible configuration modes, please refer to the related description in embodiment S12.3.
[0125] According to the ninth to fourteenth aspects, in a possible implementation process, the width of the current block is equal to or greater than a threshold value, and / or the height of the current block is equal to or greater than a threshold value. The threshold value may be 4, 8, or 16, but is not limited thereto.
[0126] It should be understood that other features and implementations of the above possible methods according to the present invention may depend on the capabilities of the corresponding devices provided in the present invention and in the various implementations.
[0127] According to a fifteenth aspect, the present invention relates to a motion vector prediction method, the method includes: obtaining index information of optimal candidate motion information of a current block; constructing a candidate motion information list according to the index information, where a mode of obtaining a motion vector included in the candidate motion information list varies with a field of the index information; determining an optimal motion vector in the candidate motion information list according to the index information; and predicting the current block according to the optimal motion vector.
[0128] According to a fifteenth aspect, in a possible implementation process, when the index information is a first feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of an HEVC mode or a non-adjacent mode.
[0129] According to a 15th aspect, in a possible implementation process, when the index information is a second feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of AFFINE mode, ATMVP mode, STMVP mode, or planar mode.
[0130] According to a fifteenth aspect, in a possible implementation process, when the index information is a third feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of HEVC mode, non-adjacent mode, ATMVP mode, or STMVP mode.
[0131] According to a fifteenth aspect, in a possible implementation process, when the index information is a fourth feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of AFFINE or planar modes.
[0132] According to a 15th aspect, in a possible implementation process, obtaining index information of optimal candidate motion information for a current block includes: if the current block satisfies a first preset condition, the obtained index information is used to indicate that a candidate motion information list for the current block should be constructed.
[0133] According to a 15th aspect, in a possible implementation process, obtaining index information of optimal candidate motion information for a current block includes: if the current block satisfies a second preset condition, the obtained index information is used to indicate that a candidate motion information list for a current sub-block should be constructed, where the current sub-block is obtained by dividing the current block.
[0134] According to a 15th aspect, in a possible implementation process, obtaining index information of optimal candidate motion information for a current block includes parsing a bitstream to obtain an index of a candidate motion information list including the optimal candidate motion information when the current block does not satisfy a first preset condition.
[0135] According to a sixteenth aspect, the present invention relates to a motion vector prediction device, which includes: an acquisition module configured to acquire index information of optimal candidate motion information of a current block; a configuration module configured to configure a candidate motion information list based on the index information, where a mode of acquiring a motion vector included in the candidate motion information list varies with a field of the index information; a determination module configured to determine an optimal motion vector from the candidate motion information list based on the index information; and a prediction module configured to predict the current block based on the optimal motion vector.
[0136] According to a sixteenth aspect, in a possible implementation process, when the index information is a first feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of an HEVC mode or a non-adjacent mode.
[0137] According to a 16th aspect, in a possible implementation process, when the index information is a second feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of AFFINE, ATMVP, STMVP, or planar modes.
[0138] According to a sixteenth aspect, in a possible implementation process, when the index information is a third feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of HEVC mode, non-adjacent mode, ATMVP mode, or STMVP mode.
[0139] According to a sixteenth aspect, in a possible implementation process, when the index information is a fourth feature value, the candidate motion information list includes candidate motion vectors obtained in at least one of AFFINE mode or planar mode.
[0140] According to a seventeenth aspect, the present invention relates to a video coding device, comprising a non-volatile memory and a processor coupled to each other, the processor calling a program code stored in the memory to execute any one of the above aspects or possible design methods.
[0141] According to an eighteenth aspect, the present invention relates to a computer-readable storage medium, which stores a computer program, which, when run on a processor, implements any one of the above aspects or possible design methods.
[0142] According to a nineteenth aspect, the present invention relates to a decoder, including a memory and a processor, which may be configured to correspondingly implement the decoding method, the decoding device, and possible implementation solutions in any one of the above aspects.
[0143] According to a twentieth aspect, the present invention relates to an encoder, including a memory and a processor, which may be configured to implement the encoding method, the encoding device, and possible implementation solutions in any one of the above aspects accordingly.
[0144] It should be understood that the functions of the encoder and the decoder may be combined with each other. Therefore, in some possible cases, the method on the decoder side may correspond to the encoder side, and the method on the encoder side may correspond to the decoder side. This invention will not describe in detail.
[0145] Due to the diversity of implementation solutions, it should be understood that the above possible implementations and descriptions may be freely combined without violating the combinatorial logic. The beneficial effects obtained in the aspects and corresponding possible implementations are similar. Details will not be described again. The details of one or more embodiments are described in the accompanying drawings and the following description. Other features, objects, and advantages are apparent from this specification, the accompanying drawings, and the claims. [Brief description of the drawings]
[0146] [Figure 1] 1 is a schematic diagram of a video encoding procedure; [Diagram 2] FIG. 1 is a schematic diagram of inter prediction. [Diagram 3] FIG. 2 is a schematic diagram of a video decoding procedure. [Figure 4] FIG. 2 is a schematic diagram of candidate locations for motion information; [Diagram 5] FIG. 13 is a schematic diagram of an advanced motion vector prediction mode of affine transformation. [Figure 6] 1 is a schematic diagram of a video transmission system. [Figure 7] 1 is a schematic diagram of motion information of spatially adjacent candidate blocks; [Figure 8] FIG. 13 is a schematic diagram of motion information for non-spatially adjacent candidate blocks. [Figure 9] FIG. 13 is a schematic diagram of an affine model merging mode. [Figure 10] FIG. 1 is a schematic diagram of a composite merge mode. [Figure 11] 1 is a schematic diagram of an ATMVP prediction mode. [Figure 12] FIG. 1 is a schematic diagram of STMVP prediction modes. [Figure 13] FIG. 1 is a schematic diagram of planar motion vector derivation. [Figure 14] FIG. 2 illustrates a decoding method according to an embodiment of the present invention. [Figure 15] FIG. 4 illustrates another decoding method according to an embodiment of the present invention. [Figure 16] FIG. 2 illustrates a syntax table according to one embodiment of the present invention. [Figure 17] FIG. 4 illustrates another decoding method according to an embodiment of the present invention. [Figure 18] FIG. 2 illustrates a decoding device according to an embodiment of the present invention. [Figure 19] FIG. 2 illustrates a coding device according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0147] The following describes embodiments of the present application with reference to the accompanying drawings in the embodiments of the present application.
[0148] As shown in Figure 1, the encoding process mainly includes the following stages: intra prediction, inter prediction, transform, quantization, entropy encode, in-loop filtering (mainly deblocking filtering), etc. After a picture is divided into coding blocks, intra prediction or inter prediction is performed. Then, after the residual is obtained, transform and quantization are performed. Finally, entropy encoding is performed, and a bitstream is output. In this specification, a coding block is an array of size MxN samples (where M may or may not be equal to N). In addition, a sample value of each sample location is given.
[0149] Intra prediction means predicting sample values of samples in a current coding block based on sample values of samples in a reconstructed area in the current picture.
[0150] Inter prediction means searching a reconstructed picture for a matched reference block for a current coding block in a current picture using sample values of samples in a reference block as prediction information or predictors (in the following no distinction is made between prediction information and predictors) of sample values of samples in a current coding block (herein this process is called motion estimation (ME) (as shown in FIG. 2B)), and transmitting the motion information of the current coding block.
[0151] It should be noted that the motion information of the current coding block includes prediction direction display information (generally forward prediction, backward prediction, or bidirectional prediction), one or two motion vectors (Motion vectors, MVs) pointing to the reference blocks, and display information of the picture in which the reference blocks are located (generally denoted as reference index).
[0152] Forward prediction means selecting a reference picture from a forward reference picture set to obtain a reference block for a current coding block. Backward prediction means selecting a reference picture from a backward reference picture set to obtain a reference block for a current coding block. Bidirectional prediction means selecting a reference picture from a forward reference picture set and a reference picture from a backward reference picture set to obtain a reference block. When a bidirectional prediction method is used, the current coding block has two reference blocks. Each reference block requires a motion vector and a reference index for display. A predictor of a sample value of a sample in the current block is determined based on the sample values of samples in the two reference blocks.
[0153] In the motion estimation process, the current coding block needs to try multiple reference blocks in the reference picture, and through rate-distortion optimization (RDO) or by using another method, the specific reference block, i.e. the specific block that will ultimately be used for prediction, is determined.
[0154] After the prediction information is obtained through intra prediction or inter prediction, the residual information is obtained by subtracting the corresponding prediction information from the sample values of the samples in the current coding block. The residual information is then transformed by using a method such as Discrete Cosine Transformation (DCT). A bitstream is then obtained through quantization and entropy coding. A filtering operation needs to be performed on the result by adding the predicted signal and the reconstructed residual signal to obtain a reconstructed signal. The reconstructed signal is used as a reference signal for subsequent coding.
[0155] Decoding is the reverse process of encoding. For example, as shown in FIG. 3, entropy decoding, inverse quantization, and inverse transform are first performed to obtain residual information, and the bitstream is decoded to determine whether intra prediction or inter prediction is used for the current coding block. If intra prediction is used, prediction information is configured based on sample values of samples in a reconstructed area around the current coding block by using an intra prediction method. If inter prediction is used, motion information needs to be parsed, and based on the motion information obtained through parsing, a reference block is determined in the reconstructed picture, and sample values of samples in the block are used as prediction information. Such a process is called motion compensation (MC). The reconstructed information can be obtained by performing a filtering operation on the result by adding the prediction information and the residual information.
[0156] In HEVC, two inter prediction modes are used: Advanced Motion Vector Prediction (AMVP) mode and Merge mode.
[0157] In the AMVP mode, a candidate motion vector list is constructed based on the motion information of the spatially or temporally neighboring coded blocks of the current coding block. Then, an optimal motion vector is determined from the candidate motion vector list, and the optimal motion vector is used as a motion vector predictor (MVP) of the current coding block. The rate distortion cost is calculated according to Equation (1), where J represents the rate distortion cost RD Cost, SAD represents the Sum of Absolute Differences (SAD) between the original sample value and the predicted sample value obtained through the motion estimation performed by using the candidate motion vector predictor, R represents the bit rate, and λ represents the Lagrange multiplier. The encoder side transfers the index value of the selected motion vector predictor in the candidate motion vector list and the reference index value to the decoder side. Furthermore, a motion search is performed in the neighboring area centered on the MVP to obtain the actual motion vector of the current coding block. The encoder side transfers the motion vector difference between the MVP and the actual motion vector to the decoder side. J = SAD + λR (1)
[0158] In merge mode, a candidate motion information list is first constructed based on the motion information of the spatially or temporally neighboring coded blocks of the current coding block, then an optimal motion information is determined from the candidate motion information list according to a rate-distortion cost criterion, the optimal motion information is used as the motion information of the current coding block, and the index value of the location of the optimal motion information in the candidate motion information list (also indicated as merge index, which also applies to the following description) is then transferred to the decoder side. The candidate motion information of the spatially or temporally neighboring coded blocks of the current coding block is shown in FIG. 4. The spatial candidate motion information comes from five spatially neighboring blocks (A0, A1, B0, B1, and B2). If the neighboring blocks are unavailable or the neighboring blocks are intra-coded, the motion information of the neighboring blocks is not added into the candidate motion information list. Based on the reference picture and the picture order count (POC) of the current picture, the temporal candidate motion information of the current coding block is obtained by scaling the MV of the co-located block in the reference picture. It is first determined whether the block at location T in the reference picture is available. If that block is unavailable, then the block at location C is selected.
[0159] It can be seen that a candidate motion vector list (sometimes called candidate list for short, also called list of candidates) needs to be maintained in both AMVP mode and merge mode. Before new motion information is added into the candidate list, it is first checked whether the same motion information already exists in the list. If the same motion information exists in the list, the motion information is not added into the list. The checking process is called pruning of the candidate motion vector list. Pruning the list prevents the existence of the same motion information in the list, which avoids redundant rate distortion cost calculation.
[0160] In HEVC inter prediction, all samples in a coding block use the same motion information, and then motion compensation is performed based on the motion information to obtain a predictor of the samples of the coding block. However, not all samples in a coding block have the same motion characteristics. Using the same motion information may lead to inaccuracies in motion compensation prediction and may result in more residual information.
[0161] In existing video coding standards, block-matching motion estimation with translational motion model is used, and all samples of a block are assumed to have matching motion. However, in the real world, there are various motions. Many objects, such as rotating objects, roller coasters rotating in different directions, fireworks, and some stunts in movies, do not have translational motion. For these moving objects, especially those in UGC (User Generated Content) scenarios, the coding efficiency is greatly affected when coding is performed by using translational motion model-based block motion compensation technology in existing coding standards. Therefore, non-translational motion models have been explored in the industry and by Huawei. In particular, affine transformation-based motion models have been thoroughly explored to further improve coding efficiency.
[0162] Non-translational motion model-based prediction means that the motion information of each motion compensation subunit in the current coding block is derived by using the same motion model at both the encoder side and the decoder side, and motion compensation is performed based on the motion information of the motion compensation subunit to obtain a prediction block, in order to improve prediction efficiency. Commonly used motion models include a six-parameter affine transformation model and a four-parameter affine transformation model.
[0163] The four-parameter affine transformation model is shown in equation (2).
[0164]
number
[0165] The four-parameter affine transformation model may be represented by using a motion vector of two samples and the coordinates of the motion vector relative to the sample at the top-left vertex of the current coding block, and the samples used to represent the motion model parameters are denoted as control points. If the samples at the top-left vertex (0,0) and top-right vertex (W,0) are used as control points, the motion vectors (vx0,vy0) and (vx1,vy1) of the control points at the top-left vertex and top-right vertex of the current coding block are first determined. Then, the motion information of each motion compensation subunit in the current coding block is derived according to equation (3), where (x,y) represents the coordinates of the motion compensation subunit relative to the sample at the top-left vertex of the current coding block, and W and H represent the width and height of the current coding block, respectively.
[0166]
number
[0167] The six-parameter affine transformation model is shown in equation (4).
[0168]
number
[0169] The six-parameter affine transformation model may be represented by using the motion vectors of three samples and their coordinates relative to the top-left sample of the current coding block. If the samples at the top-left vertex (0,0), top-right vertex (W,0), and bottom-left vertex (0,H) are used as control points, the motion vectors (vx0,vy0), (vx1,vy1), and (vx2,vy2) of the control points at the top-left vertex, top-right vertex, and bottom-left vertex of the current coding block are first determined. Then, the motion information of each motion compensation subunit in the current coding block is derived according to equation (5), where (x,y) represents the coordinates of the motion compensation subunit relative to the sample at the top-left vertex of the current coding block, and W represents the width of the current coding block.
[0170]
number
[0171] The eight-parameter bilinear model is shown in equation (6).
[0172]
number
[0173] The eight-parameter bilinear model may be represented by using the motion vectors of four samples and the coordinates of the motion vectors relative to the sample at the top-left vertex of the current coding block. If the samples at the top-left vertex (0,0), top-right vertex (W,0), bottom-left vertex (0,H), and bottom-right vertex (W,H) are used as control points, the motion vectors (vx0,vy0), (vx1,vy1), (vx2,vy2), and (vx3,vy3) of the top-left vertex, top-right vertex, bottom-left vertex, and bottom-right vertex control points of the current coding block are first determined. Then, the motion information of each motion compensation subunit in the current coding block is derived according to equation (7), where (x,y) represents the coordinates of the motion compensation subunit relative to the sample at the top-left vertex of the current coding block, and W and H are the width and height of the current coding block, respectively.
[0174]
number
[0175] A coding block that is predicted according to a non-translational motion model is called a non-translational coding block.
[0176] In general, the motion information of the control points of the non-translation coding block may be obtained in an affine transform-based Advanced Motion Vector Prediction (AMVP) mode or an affine transform-based Merge mode.
[0177] The following describes a method for obtaining the motion information of two control points in a four-parameter affine transformation model.
[0178] Affine transformation based advanced motion vector prediction mode:
[0179] (1) Construction of candidate motion vector 2-tuple
[0180] The motion vectors of the top-left vertex and the top-right vertex of the current coding block are determined based on the motion information of the neighboring coding blocks of the current coding block. As shown in Figure 5, the motion vectors of the neighboring coding blocks A, B, and C of the top-left vertex are used as the candidate motion vector of the top-left vertex of the current coding block, and the motion vectors of the neighboring coding blocks D and E of the top-right vertex are used as the candidate motion vector of the top-right vertex of the current block. The candidate motion vector of the top-left vertex and the candidate motion vector of the top-right vertex are combined to form a candidate motion vector 2-tuple queue of two control points. {(v 0A ,v 1D ),(v 0A ,v 1E ),(v 0B ,v 1D ),(v 0B ,v 1E ),(v 0C ,v 1D ),(v 0C ,v 1E )}
[0181] v0 represents the candidate motion vector for the top-left vertex, v1 represents the candidate motion vector for the top-right vertex, and the locations of the candidate motion vectors in the queue are indexed, where the index values are 0, 1, 2, 3, 4, and 5.
[0182] Optionally, the candidate motion vector 2-tuple queue may be pruned and sorted according to a particular rule, and truncation and filling may be performed on the candidate motion vector 2-tuple queue to obtain a particular quantity of elements contained in the queue.
[0183] (2) Determining the best candidate motion vector 2-tuple
[0184] At the encoder side, the motion vector of each motion compensation sub-unit (which is a sample or sample block of size N_1×N_2 obtained through division by using a specific method) in the current coding block is obtained by using each candidate motion vector 2-tuple according to equation (3) to obtain the sample value of the location in the reference picture to which the motion vector of each motion compensation sub-unit points. The sample value is used as a predictor of the sample value of the sample in the current coding block for affine transformation motion compensation. The average value of the difference between the original value and the predictor of the sample in the current coding block is calculated, and the motion vector in the candidate motion vector 2-tuple corresponding to the minimum difference average is selected as the motion vector predictor of the two control points in the current coding block. The index value representing the location of the 2-tuple in the candidate motion vector 2-tuple queue is coded into the bitstream and sent to the decoder.
[0185] At the decoder side, the index values are parsed to obtain the motion vector predictors for the two control points.
[0186] (3) Determining the motion vectors of the control points
[0187] At the encoder side, a motion search is performed within a certain search range by using the motion vector predictors of the two control points as search starting points to obtain the motion vectors of the two control points. The difference between the motion vectors of the two control points and the motion vector predictors is transferred to the decoder side.
[0188] At the decoder side, the motion vector difference of the two control points is parsed and added to the motion vector predictor to obtain the motion vector of the control point.
[0189] FIG. 6 shows a system framework according to the present invention. The present invention mainly relates to video encoding and video decoding within the system framework. Existing video transmission systems generally include collection, encoding, sending, receiving, decoding, and display. The collection module includes a camera or a camera module and a pre-processor, which converts an optical signal into a digital video sequence. The video sequence is then encoded by an encoder and converted into a bitstream. The bitstream is then sent by a sending module through a network to a receiving module, where it is converted by the receiving module, decoded by a decoder, and reconstructed into a video sequence. Finally, the reconstructed video sequence undergoes post-processing such as rendering, and is sent to a display device for display.
[0190] The present invention relates primarily to video encoding and decoding within a system framework.
[0191] The application scenario of the present invention is shown in a hybrid coding framework based video encoding and decoding system shown in Figure 1 and Figure 2. The encoding process as shown in Figure 1 mainly includes intra prediction, inter prediction, transform, quantization, entropy encoding, loop filter, and other steps. These procedures are mainly used to implement the following operations respectively: obtaining a prediction block from adjacent samples of a current picture, calculating MV information and obtaining a prediction block from a reference picture, transforming residuals from sample domain to transform domain, compressing transform domain coefficients, compressing coding information, and performing post-processing on a reconstructed picture. The operations in the decoding system as shown in Figure 2 are the reverse processes performed in the encoding process. The present invention is mainly applied to inter prediction in video encoding and decoding systems.
[0192] Embodiment 1 (encoder side) Brief description: list0 and list1 are configured with various motion information list configuration modes for a current block (Block). list0 is a candidate motion vector list used for a current block when the current block is predicted by using a block as a basic prediction unit. list1 is a candidate motion vector list used for a current block when the current block is predicted by using a sub-block as a basic prediction unit. The current block may be divided into multiple sub-blocks, and each sub-block may be in the shape of a square or a rectangle. The sub-blocks may be, for example, but not limited to, 4×4, 8×8, or 4×8 in size. list0 and list1 include candidate motion information. The candidate motion information includes motion vectors, prediction directions, reference indexes, etc. In short, list0 and list1 are configured with various motion information list configuration modes applicable to the features of the current block.
[0193] For example, the block-based list0 may include an HEVC mode and a non-adjacent mode, The subblock-based list1 may include an AFFINE mode (including a motion model-based affine model merge mode and / or a control point-based composite merge mode), an ATMVP mode, a STMVP mode, and a planar mode.
[0194] In a particular implementation process, the block-based list0 may include one or more of the candidate motion vector derivation modes, such as the HEVC mode and the non-adjacent mode, and the subblock-based list1 may include one or more of the candidate motion vector derivation modes, such as the AFFINE mode, the ATMVP mode, the STMVP mode, and the planar mode. For example, the list1 may alternatively include only the ATMVP mode. In the present application, multiple modes may be used for description.
[0195] S11: Construct a first candidate motion information list (List0) of the current coding block, that is, construct a block-based candidate motion information list. The motion information in List0 may be referred to as block-based candidate motion information.
[0196] S11.1: Motion information of spatially and / or temporally neighboring coding blocks of a current coding block is added into a first candidate motion information list according to a preset rule in the HEVC mode.
[0197] Figure 7 shows the motion information of spatially adjacent candidate blocks. At the leftmost, spatial candidate blocks are selected in the following sequence: a1, b1, b0, a0, and (b2). If any of the first four blocks is unavailable, check whether the motion information of b2 exists and is available. If the motion information of b2 exists and is available, add the motion information of b2 into the candidate motion information list. Then, the temporal candidate motion information and / or the zero vector are considered to be added into the motion information list. It should be understood that there may be multiple preset rules for selecting spatial candidates and temporal candidates. This is not limited in the present invention.
[0198] In a possible implementation process, the derived sequence may be a0, b0, b1, a1, and b2. Location b2 is considered only if any CU in locations a0, b0, b1, and a1 is unavailable (e.g., the CU belongs to another slice or another tile) or the CU is intra-coded. After the candidate location a1 is added, a redundancy check needs to be performed when the remaining candidates are added. The redundancy check prevents candidate items with the same motion information from being added into the list, thereby improving coding efficiency. To reduce the computational complexity, some candidates may be selectively considered in the redundancy check. For example, a candidate is added into the list only when there is no same motion information for the corresponding candidate used for the redundancy check.
[0199] In one possible implementation, the maximum number of spatial candidate blocks is 4. In addition, when the number of pieces of candidate motion information in list0 (excluding repeated ineligible information) is equal to MaxNumMergeCand, the insertion or appending is stopped. The maximum number of pieces of candidate motion information in candidates List1, MaxNumMergeCand, may be transmitted in the bitstream, or a default value may be used during encoding and decoding. In this embodiment, the maximum number of candidate motion information pieces is, for example, 5.
[0200] Optionally, the block-based candidate motion information list includes a candidate motion information list configured in a conventional merge mode (which may also be expressed as a general_merge or regular_merge mode in some scenarios) defined according to the HEVC standard or an advanced version of the HEVC standard. All candidate motion information in the block-based candidate motion information list may be motion information of coded blocks that are spatially or temporally adjacent to the current block. Alternatively, some candidate motion information may be motion information of coded blocks that are spatially or temporally adjacent to the current block, and some of the candidate motion information may be motion information obtained in another manner.
[0201] S11.2: Add motion information of coding blocks that are not spatially adjacent to the current coding block to a first candidate motion information list according to a preset rule.
[0202] The motion vectors of spatially non-adjacent candidate blocks are shown in the following diagram (FIG. 8). The spatial candidate blocks are selected in the following sequence, namely, candidate block 6 to candidate block 49. After the availability is checked and the repeated items are removed, the motion information corresponding to the available location blocks is inserted consecutively into the first candidate motion information list. The insertion is stopped when the number of pieces of candidate motion information in list0 (excluding the repeated ineligible information) is equal to MaxNumMergeCand.
[0203] List0 is constructed based on S11.1 and S11.2. If the number of pieces of candidate motion information in list0 (excluding repeated unqualified information) is less than 5, the number of pieces of candidate motion information in the list can be made to reach a specified number by adding zero motion vectors. For example, the first candidate motion information list (List0) of the current block may be in the following format:
[0204] [Table 1]
[0205] Alternatively, the first candidate motion information list (List0) for the current block may be in the following format:
[0206] [Table 2]
[0207] Please note that in the present invention, in S11 that constitutes a block-based candidate motion information list, the sequence of adding candidate motion information in S11.1 to the list and adding candidate motion information in S11.2 to the list is not limited. The motion information in S11.1 can be added first, the motion information in S11.2 can be added second, the motion information in S11.2 can be added first, the motion information in S11.1 can be added second, or the motion information in S11.1 and S11.2 can be added alternately to the list. Alternatively, one or both of S11.1 and S11.2 can be performed on S11.
[0208] S12: Construct a second candidate motion information list (List1) for the current coding sub-block, i.e., construct a sub-block-based candidate motion information list. The motion information in list1 may be referred to as sub-block-based candidate motion information.
[0209] S12.1: Motion information of spatially adjacent coding blocks of a current coding block is added into a second candidate motion information list (List1) according to pre-set rules in a motion model-based Affine model merge (AMM) mode.
[0210] In order to improve coding efficiency when the current block is an affine transformation prediction block, when the motion information of the control points of the current block is coded, one block is selected from the neighboring blocks of the current block according to a preset selection policy, and the motion information of the vertices of the current block is derived based on the motion information of the vertices of the selected block (this is sometimes called luma affine control point motion vectors from a neighbouring block in the standard). The encoder side does not need to transmit the display information of the selected neighboring block to the decoder side. In this case, the current block and the neighboring block use the same affine transformation model.
[0211] As shown in FIG. 9, A, B, C, D, and E are adjacent coding blocks of the current coding block, and a traversal is performed in the sequence of A, B, C, D, and E to find an affine coding block, and the motion information of the control points of the affine coding block is obtained, and the motion information of the upper-left vertex and the upper-right vertex of the current coding block is further derived.
[0212] The following uses A as an example to explain the derivation process, and other cases are similar. If the coding block corresponding to A is an affine coding block, the motion vector (vx2, vy2) of the upper left vertex (x2, y2) and the motion vector (vx3, vy3) of the upper right vertex (x3, y3) of the affine coding block are obtained. The motion vector (vx0, vy0) of the upper left vertex (x0, y0) of the current coding block is calculated according to equation (8). The motion vector (vx1, vy1) of the upper right vertex (x1, y1) of the current coding block is calculated according to equation (9).
[0213]
number
[0214]
number
[0215] After the availability is checked and the repeated items are removed, the motion information corresponding to the available location blocks is inserted consecutively into a second candidate motion information list (List1). The insertion is stopped when the number of pieces of candidate motion information in list1 (excluding the repeated ineligible information) is equal to MaxNumMergeCand.
[0216] S12.2: Add the motion information of the spatially adjacent coding blocks of the current coding block into a second candidate motion information list (List1) according to a preset rule in a control point-based complex merge mode (Complex merge mode).
[0217] First, the motion information of each control point is derived. As shown in Figure 10, k (k=1,2,3,4) represents the kth control point. A0, A1, A2, B0, B1, B2, and B3 represent the spatially adjacent locations of the current block, and CP k (k=1,2,3) is used to predict T r represents a temporally adjacent location of the current block and is used to predict CP4.
[0218] The coordinates of CP1, CP2, CP3, and CP4 are (0,0), (W,0), (H,0), and (W,H), respectively, where W and H represent the width and height of the current block.
[0219] For each control point, the motion information of the control point is obtained in the following sequence.
[0220] For CP1, the check sequence is B2->A2->B3. If B2 is available, the motion information of B2 is used. If not, A2 and B3 are checked. If the motion information of all three locations is unavailable, the motion information of CP1 cannot be obtained.
[0221] For CP2, the check sequence is B0->B1.
[0222] For CP3, the check sequence is A0->A1.
[0223] For CP4, T r The motion information is used.
[0224] As used herein, "available" means that the block at location X is coded and is inter-coded. Otherwise, location X is unavailable.
[0225] It should be noted that other methods for obtaining the motion information of the control points are also applicable to the present invention, and will not be described in detail herein.
[0226] The motion information of the control points is then combined to obtain non-translational (affine model-based) motion information.
[0227] The motion information of two control points is combined to construct a four-parameter affine transformation model. Two of the control points are combined as follows: {CP1,CP4}, {CP2,CP3}, {CP1,CP2}, {CP2,CP4}, {CP1,CP3}, and {CP3,CP4}. For example, the four-parameter affine transformation model constructed using control points CP1 and CP2 is denoted as affine(CP1,CP2).
[0228] The motion information of the three control points is combined to construct a six-parameter affine transformation model. Three of the control points are combined as follows: {CP1,CP2,CP4}, {CP1,CP2,CP3}, {CP2,CP3,CP4}, and {CP1,CP3,CP4}. For example, the six-parameter affine transformation model constructed using control points CP1, CP2, and CP3 is denoted as affine(CP1,CP2,CP3).
[0229] The motion information of the four control points is combined to construct an eight-parameter bilinear model. The eight-parameter bilinear model constructed using control points CP1, CP2, CP3, and CP4 is denoted as bilinear(CP1,CP2,CP3,CP4).
[0230] These models (different types or the same type) are traversed in a pre-configured sequence. If the motion information of the control points corresponding to the composite model is unavailable, the model is considered unavailable. Otherwise, the reference index of the model (the motion vectors of all control points point to the same reference picture) is determined, and the motion vectors of the control points are scaled. For example, the motion vectors are scaled according to equation (10). The scaling factor is the ratio of the distance from the current picture to the reference picture to the distance from the current picture to the reference picture of the neighboring block. If the motion information of all control points is consistent after scaling, the model is invalid. Otherwise, the motion information of the control points that constitute the model is added into the candidate motion information list.
[0231]
number
[0232] After the availability is checked and the repeated items are removed, the motion information corresponding to the available location blocks is inserted consecutively into a second candidate motion information list (List1). The insertion is stopped when the number of pieces of candidate motion information in list1 (excluding the repeated ineligible information) is equal to MaxNumMergeCand.
[0233] In the latest standard, the candidate motion information obtained in the complex merge mode is called “constructed affine control point motion vector merging candidates.”
[0234] S12.3: Add the ATMVP and / or STMVP candidate motion vectors into a second candidate motion information list (List1) according to a preset rule.
[0235] By using the Sub-BLOCK-based motion vector prediction (SMVP) technique, the current coding unit is divided into coding subunits, each of which has a size of M×N, motion information of each coding subunit is derived, and then motion compensation is performed based on the motion information of all the coding subunits to obtain a predictor for the current coding unit.
[0236] In this technique, there are two types of candidate motion information in merge mode: advanced temporal motion vector prediction (ATMVP) candidate motion information and spatial-temporal motion vector prediction (STMVP) candidate motion information.
[0237] In the ATMVP technology, as shown in FIG. 11, a collocated reference picture is first determined, a current coding unit (current block) is divided into coding subunits (coding subblocks), each of which has a size of M×N, motion information of a center point location sample of the coding subunit corresponding to each current coding subunit and located in the collocated reference picture is obtained, the motion information is scaled, and the motion information is converted into the motion information of each current coding subunit.
[0238] In the STMVP technique, the motion information of each current coding subunit in the spatially adjacent upper location, the spatially adjacent left location, and the temporally adjacent lower right location is obtained, the average value of the motion information is calculated, and the calculated average value is converted into the motion information of each current coding subunit. As shown in the following figure (Figure 12), the current coding unit is divided into four coding subunits, namely, A, B, C, and D. A is used as an example. The motion information of coding subunit A is derived based on the motion information of spatially adjacent locations c and b, and the motion information of location D in the co-located reference picture.
[0239] After the availability is checked and the repeated items are removed, the motion information corresponding to the available location blocks is inserted consecutively into a second candidate motion information list (List1). The insertion is stopped when the number of pieces of candidate motion information in list1 (excluding the repeated ineligible information) is equal to MaxNumMergeCand.
[0240] S12.4: Add the planar candidate motion information into a second candidate motion information list (List1) according to a preset rule.
[0241] See Figure 13. The motion information of the MxN blocks that are temporally adjacent to the current block on the lower right is obtained. The motion information R(W,y) of each adjacent right MxN block is obtained through vertical interpolation according to the following formula based on the motion information (AR) of the spatially adjacent upper right block and the motion information (BR) of the temporally adjacent lower right MxN block, where MxN represents the size of the block: R(W,y)=((Hy-1)×AR+(y+1)×BR) / H
[0242] The motion information (B(x,H)) of each adjacent lower M×N block is obtained through horizontal interpolation based on the motion information (BL) of the spatially adjacent lower left M×N block and the motion information (BR) of the temporally adjacent lower right M×N block, according to the following formula: B(x,H)=((Wx-1)×BL+(x+1)×BR) / W
[0243] (x,y) represent the coordinates of the current MxN subblock relative to the top-left subblock of the current block. W and H represent the width and height (measured in subblock units) of the current block, respectively. AR represents the motion information of the spatially adjacent top-right MxN block. BR represents the motion information of the temporally adjacent bottom-right MxN block. BL represents the motion information of the spatially adjacent bottom-left MxN block.
[0244] The motion information of each sub-block is obtained in the following manner.
[0245] According to the motion vector of the neighboring left M×N block and the motion vector of the neighboring right M×N block in the row where the current sub-block is located, a horizontal motion vector is obtained through horizontal interpolation according to the following formula: P h (x,y)=(W-1-x)×L(-1,y)+(x+1)×R(W,y)
[0246] According to the motion vector of the adjacent upper M×N block and the motion vector of the adjacent lower M×N block in the row where the current sub-block is located, a vertical motion vector is obtained through vertical interpolation according to the following formula: P v (x,y)=(H-1-y)×A(x,-1)+(y+1)×B(x,H)
[0247] The average value of the motion vectors obtained through horizontal and vertical linear interpolation is obtained according to the following formula, that is, the motion vector of each sub-block is: P(x,y)=(H×P n (x,y)+W×Pv (x,y)+H×W) / (2×H×W)
[0248] L(-1,y) and R(W,y) respectively represent the motion vectors of the adjacent left M×N block and the adjacent right M×N block in the row in which the current subblock is located. A(x,-1) and B(x,H) respectively represent the motion vectors of the adjacent upper M×N block and the adjacent lower M×N block in the column in which the current subblock is located. P h (x,y) represents the motion vector obtained through horizontal interpolation. v (x,y) represents the motion vector obtained through vertical interpolation.
[0249] If all spatially and temporally adjacent blocks (and temporally adjacent blocks) contain the same motion information in the list (only existing and processed motion information), the list is unavailable. If both lists are unavailable, the planar motion information is unavailable. Alternatively, if all spatially adjacent blocks (and temporally adjacent blocks) contain the same motion information in the list (only existing and processed motion information), the same motion information is the motion information of all sub-blocks of the current coding block in the list.
[0250] After the availability is checked and the repeated items are removed, the motion information corresponding to the available location blocks is inserted consecutively into a second candidate motion information list (List1). The insertion is stopped when the number of pieces of candidate motion information in list1 (excluding the repeated ineligible information) is equal to MaxNumMergeCand.
[0251] List1 is constructed based on S12.1 to S12.4. If the number of pieces of candidate motion information in list1 (excluding repeated unqualified information) is less than 5, the number of pieces of candidate motion information in the list can be made to reach a specified number by adding zero motion vectors. For example, the second candidate motion information list (List1) of the current block may have the format shown in Table 3.
[0252] [Table 3]
[0253] Alternatively, the second candidate motion information list (List1) of the current block may be in the format shown in Table 4.
[0254] [Table 4]
[0255] Please note that in the present invention, in S12 that constitutes a sub-block-based candidate motion information list, the sequence of adding candidate motion information in S12.1, S12.2, S12.3 or S12.4 into the list is not limited. Candidate motion information can be added in a specific sequence, or different types of motion information can be added alternately into the list, or one or more of the candidate motion information in S12.1, S12.2, S12.3 and S12.4 can be added into the list.
[0256] It should be understood that the subblock-based candidate motion information list is a candidate motion information list configured in a subblock-based merge mode (merge_subblock) mode, and the subblock-based candidate motion information list may include a candidate motion information list configured in at least one subblock-based merge mode of affine model merge, complex merge, or ATMVP. All candidate motion information in the subblock-based candidate motion information list may be obtained through derivation in affine model merge mode, or in complex merge mode, or only in ATMVP mode, or in multiple different modes. The multiple different modes may be any combination of the three modes, affine model merge, complex merge, and ATMVP. In some possible cases, the candidate motion information list may further include motion information obtained in another subblock-based mode. The candidate motion information may be added into the list as follows: That is, the candidate motion information derived in ATMVP mode may be added first, and then the candidate motion information derived in another mode may be added. The synthesis method and the adding sequence are not enumerated or described in detail in the present invention.
[0257] Optionally, a block including 2×2 sub-blocks is used as an example. A possible implementation form of the sub-block-based constructed candidate motion information list list1 is {ATMVP((MV x01 ,MV y01 )(MV x02 ,MV y02 )(MV x03 ,MV y03 )(MV x04 ,MV y04 )),(MV x1 ,MV y1 ),(MV x2 ,MV y2 ),(MV x3 ,MV y3 ),(MV x4 ,MV y4)}. If the value of index is 0, the corresponding prediction is x01 ,MV y01 )(MV x02 ,MV y02 )(MV x03 ,MV y03 )(MV x04 ,MV y04 ) for the four sub-blocks. If the value of index is 1, each MV of the sub-blocks of the current block is calculated based on the (MV x1 ,MV y1 ) Then, each sub-block of the current block is predicted based on each derived MV.
[0258] Optionally, a possible implementation form of the sub-block based constructed candidate motion information list list1 is: {ATMVP(MV x1 ,MV y1 ),(MV x2 ,MV y2 ),(MV x3 ,MV y3 ),(MV x4 ,MV y4 )}. If the value of index is 0, the motion information finally used is obtained through ATMVP. If the value of index is 1, the motion information used is the (MV x1 ,MV y1 ) is a derived MV.
[0259] S13: Select the best candidate motion information from the two lists.
[0260] The best candidate motion information is determined from the two candidate motion information lists according to the minimum rate distortion cost criterion, and the best candidate motion information is used as the motion information of the current coding block. Then, the index (for example, list-idx) of the candidate motion information list containing the best candidate motion information and the index value (for example, mv-idx) of the location of the best candidate motion information in the list are transferred to the decoder side. The rate distortion cost is calculated according to the following formula, where J represents the rate distortion cost RD Cost, SAD represents the Sum of Absolute Differences (SAD) between the original sample value and the predicted sample value obtained through the motion compensation performed by using the candidate motion information, R represents the bit rate, and λ represents the Lagrange multiplier. The encoder side sends the index value of the selected motion information in the candidate motion information list to the decoder side. J = SAD + λR
[0261] S14: Perform motion compensation on the current block based on the best candidate motion information obtained in S13 to obtain a sample predictor of the block.
[0262] In addition, it should be understood that "0" and "1" in list0 and list1 are only used for distinction. Whether list0 or list1 is designated as a block-based list or a sub-block-based list may be determined according to a preset rule. This is not limited in the present application.
[0263] In particular, if the optimal motion information is the motion information in the block-based candidate motion information list, the current block is predicted based on the optimal motion information.
[0264] In particular, when the optimal motion information is the motion information in the sub-block-based candidate motion information list, at least the following two cases are included:
[0265] Case 1: When optimal motion information is obtained in an affine mode (including at least an affine model merge mode or a complex merge mode), motion information corresponding to a sub-block of a current block is derived based on the optimal motion information, and the sub-block of the current block is predicted. The current block may include multiple sub-blocks, and the sub-block of the current block may be any one of the multiple sub-blocks.
[0266] In a possible implementation process, the motion information corresponding to each sub-block of the current block is derived based on the optimal motion information, and each sub-block of the current block is predicted correspondingly.
[0267] Case 2: If the optimal motion information is derived through ATMVP, the sub-blocks of the current block are predicted based on the optimal motion information.
[0268] In a possible implementation process, the optimal candidate motion information may be a combination of motion information, including motion information corresponding to each sub-block of the current block, each sub-block of the current block being correspondingly predicted.
[0269] In addition, it should be further understood that performing prediction based on the optimal motion information may include directly performing prediction based on the optimal motion information, or may include deriving optimal motion information and predicting the optimal motion information based on the derived motion information, or may include correcting the optimal motion information and performing prediction based on the motion information obtained through the correction.
[0270] The above examples are merely some possible implementations of the present invention and are not intended to be limiting in any way, as other examples are not necessarily described in the present invention.
[0271] Optionally, the width of the current block is greater than or equal to a threshold value and / or the height of the current block is greater than or equal to a threshold value, which may be, but is not limited to, 4, 8, or 16.
[0272] According to embodiment 1, the following method flow can be obtained.
[0273] S1301: Construct a first list, where the first list is a block-based candidate motion information list.
[0274] S1302: Construct a second list, where the second list is a sub-block-based candidate motion information list.
[0275] S1303: Determine optimal candidate motion information from the first candidate motion information list and the second candidate motion information list.
[0276] S1304: Predict the current block based on the optimal motion information.
[0277] The method may also further include the following steps.
[0278] S1305: Obtain an identifier used to determine a candidate motion information list including optimal candidate motion information for the current block, and obtain an index of the optimal candidate motion information in the candidate motion information list, where the inter prediction mode used for the current block is merge mode, and when the identifier is a first feature value, the candidate motion information list is the first list, or when the identifier is a second feature value, the candidate motion information list is the second list.
[0279] S1306: Encode the identifier and the index into a bitstream.
[0280] S1305 and S1306 may further independently perform new encoding methods, the details of which are not described in this specification.
[0281] The difference between embodiment 1 and current technology is as follows: multiple types of candidate motion information are inserted into different candidate motion information lists, the best candidate motion information is selected according to RDO criterion, and the best candidate motion information is transferred to the decoder side. According to embodiment 1, the BLOCK-based candidate motion information list and the Sub-BLOCK-based candidate motion information list can be distinguished from each other, so that the BLOCK-based candidate motion information list and the Sub-BLOCK-based candidate motion information list are obtained. This effectively reduces the transmission cost of the best candidate motion information.
[0282] Embodiment 2 (Decoder side) Brief description: the candidate motion information of a current block (Block) and the candidate motion information of a current sub-block (Sub-BLOCK) can be inserted (or configured) into list0 and list1, respectively, when obtaining a mode of the candidate motion information.
[0283] The block-based list0 includes the HEVC mode and the non-adjacent mode.
[0284] The subblock-based list1 includes the AFFINE mode (including the motion model-based affine model merging mode or the control point-based composite merging mode), the ATMVP mode, the STMVP mode, and the planar mode.
[0285] In a specific implementation process, the block-based list0 may include one or more of the candidate motion vector derivation modes, such as the HEVC mode (general_merge or regular_merge) and the non-adjacent mode, and the subblock-based list1 may include one or more of the candidate motion vector derivation modes, such as the AFFINE mode, the ATMVP mode, the STMVP mode, and the planar mode. In the present application, multiple modes may be used for description. For example, the list1 may alternatively include only the ATMVP mode.
[0286] S21: Parse the bitstream to obtain index information of the best candidate motion information.
[0287] In particular, the bitstream is parsed to obtain an index (e.g., list-idx) of a candidate motion information list that contains the best candidate motion information, and an index value (e.g., mv-index) of the location of the best candidate motion information in the list. It should be understood that more syntax elements may be further obtained by parsing the bitstream, and the list index is only a possible implementation.
[0288] S22: Construct a candidate motion information list based on the candidate motion information list index.
[0289] For example, but not limited to, the following cases are possible:
[0290] When list-idx=0, a specific implementation may be performed by using the same or similar method as in S11. For example, a block-based candidate motion information list is configured in the mode in S11.1 and / or S11.2. For example, the candidate motion information list may be, but is not limited to, the list shown in Table 1 or Table 2.
[0291] When list-idx=1, a specific implementation may be performed by using the same or similar method as in S12. For example, the sub-block-based candidate motion information list is configured in the modes in S12.1, S12.2, and / or S12.3. For example, the candidate motion information list may be, but is not limited to, the list shown in Table 3 or Table 4.
[0292] It can be seen from the table that a specific motion vector can be determined under the condition that the index of the motion vector list (list-idx) and the index of the vector in the list (mv-index) are determined. Optionally, the identifier of the index may be represented as, for example, list-idx. However, this is not limited. Optionally, the value of the identifier of the index list-idx may include, but is not limited to, 0 or 1. Optionally, the candidate motion information list configured in the block-based mode may be represented as list0 (or list1), and the candidate motion information list configured in the sub-block-based mode may be represented as list1 (or list0). The "block-based mode" refers to a mode that performs prediction based on a current block, and the "sub-block-based mode" refers to a mode that performs prediction based on a sub-block, where the sub-block is obtained by dividing the current block into multiple sub-blocks.
[0293] It should be understood that the particular values of the feature values, or the format of the identifiers, or the particular representation symbols of the lists are not limiting and are not necessarily exhaustively described herein.
[0294] It will be understood that the list index, or similar identifier, or similar syntax element may be used to determine a candidate motion information list containing optimal candidate motion information for the current block, or may be used to determine a mode for constructing a candidate motion information list containing optimal candidate motion information for the current block, or may be used to indicate whether a conventional merging mode or a sub-block based merging mode is used for the current block.
[0295] Optionally, when the bitstream is parsed, the obtained syntax element may include a list index, and determining based on the syntax element that a first list or a second list should be constructed for the current coding block includes obtaining a candidate motion information list index, where when the list index is a first feature value, it indicates that a first list should be constructed for the current coding block, or when the list index is a second feature value, it indicates that a second list should be constructed for the current coding block.
[0296] Optionally, when the bitstream is parsed, the syntax elements obtained may include indication information used to indicate the conventional merging mode to be used for the current block, or indication information used to indicate the sub-block based merging mode to be used for the current block.
[0297] Optionally, when the bitstream is parsed, the syntax elements obtained may include display information used to determine that a block-based candidate motion information list is used for the current block, or display information used to determine that a sub-block-based candidate motion information list is used for the current block.
[0298] S23: Determine optimal candidate motion information based on the index information.
[0299] In particular, the best candidate motion information is determined from the list based on the list-idx and the mv-index.
[0300] For example, if list-idx=0 and mv-index=0, the motion information of the current block is MVB1.
[0301] S24: Perform motion compensation on the current block based on the best candidate motion information obtained in S23 to obtain a sample predictor of the block.
[0302] The particular prediction mode may correspond to a prediction mode on the encoder side.
[0303] In particular, if the optimal motion information is the motion information in the block-based candidate motion information list, the current block is predicted based on the optimal motion information.
[0304] In particular, when the optimal motion information is the motion information in the sub-block-based candidate motion information list, at least the following two cases are included:
[0305] Case 1: When the optimal motion information determined in S23 is obtained in an affine mode (including at least an affine model merge mode or a complex merge mode), motion information corresponding to a sub-block of a current block is derived based on the optimal motion information, and the sub-block of the current block is predicted. The current block may include multiple sub-blocks, and the sub-block of the current block may be any one of the multiple sub-blocks.
[0306] In a possible implementation process, the motion information corresponding to each sub-block of the current block is derived based on the optimal motion information, and each sub-block of the current block is predicted correspondingly.
[0307] Case 2: If the optimal motion information determined in S23 is obtained in ATMVP mode, the sub-blocks of the current block are predicted based on the optimal motion information.
[0308] In a possible implementation process, the optimal candidate motion information may be a combination of motion information, including motion information corresponding to each sub-block of the current block, each sub-block of the current block being correspondingly predicted.
[0309] Case 3: When the optimal motion information determined in S23 is obtained in ATMVP mode through a display, the optimal motion information is obtained based on the corresponding display, and the sub-blocks of the current block are predicted based on the optimal motion information.
[0310] In a possible implementation process, the optimal candidate motion information can be obtained based on display information. The motion information corresponding to each sub-block of the current block can be obtained in ATMVP mode based on display information, and each sub-block of the current block is predicted correspondingly.
[0311] In addition, it should be further understood that performing prediction based on the optimal motion information may include directly performing prediction based on the optimal motion information, or may include deriving the optimal motion information and performing prediction based on the motion information obtained through the derivation, or may include correcting the optimal motion information and performing prediction based on the motion information obtained through the correction.
[0312] The above examples are merely some possible implementations of the present invention and are not intended to be limiting in any way, as other examples are not necessarily described in the present invention.
[0313] Optionally, the width of the current block is greater than or equal to a threshold value and / or the height of the current block is greater than or equal to a threshold value, which may be, but is not limited to, 4, 8, or 16.
[0314] In conclusion, according to embodiment 1 and embodiment 2, the following method steps can be obtained in the present invention: Please refer to Figure 14 and Figure 15.
[0315] The decoding method is shown in Figure 14. The method includes the following steps:
[0316] S141: Obtain a configuration mode of a candidate motion information list including optimal candidate motion information of the current block, and obtain an index of the optimal candidate motion information in the candidate motion information list, where the configuration mode of the candidate motion information list is a mode of constructing a block-based candidate motion information list, or a mode of constructing a sub-block-based candidate motion information list.
[0317] For optional methods, please refer to S21 in this embodiment.
[0318] In detail, an identifier is obtained that is used to determine a candidate motion information list. The inter-prediction mode used for the current block is a merge mode. When the identifier is a first feature value, the configuration mode of the candidate motion information list is a mode of configuring a block-based candidate motion information list, or when the identifier is a second feature value, the configuration mode of the candidate motion information list is a mode of configuring a sub-block-based candidate motion information list.
[0319] For the optional method, please refer to the function of the identifier in S22 in this embodiment.
[0320] S142: Configure a candidate motion information list in a configuration mode.
[0321] For optional methods, please refer to S22 in this embodiment.
[0322] For the construction of the block-based candidate motion information list, please refer to S11.1 and / or S11.2 in this embodiment.
[0323] For the construction of the sub-block-based candidate motion information list, please refer to S12.1, S12.2, S12.3, and / or S12.4 in this embodiment.
[0324] S143: Determine the best motion information from the constructed candidate motion information list based on the index. For an optional manner, please refer to S13 in this embodiment.
[0325] S144: Predict the current block based on the optimal motion information. For an optional method, please refer to S14 in this embodiment.
[0326] The decoding method is shown in Figure 15. The method includes the following steps:
[0327] S151: Parse a bitstream to obtain a syntax element, where the syntax element includes at least an index of a best candidate motion information of a current block.
[0328] For optional methods, please refer to S21 in this embodiment.
[0329] S152: Determine based on a syntax element that a first list or a second list should be constructed for the current block, where the first list is a block-based candidate motion information list and the second list is a sub-block-based candidate motion information list.
[0330] For optional methods, please refer to S22 in this embodiment.
[0331] For the construction of the block-based candidate motion information list, please refer to S11.1 and / or S11.2 in this embodiment.
[0332] For the construction of the sub-block-based candidate motion information list, please refer to S12.1, S12.2, S12.3, and / or S12.4 in this embodiment.
[0333] S153: Determine optimal motion information from the first list or the second list based on the index.
[0334] For optional methods, please refer to S23 in this embodiment.
[0335] S154: Predict the current block based on the optimal motion information.
[0336] For optional methods, please refer to S24 in this embodiment.
[0337] The specific implementation solutions have been fully described in the above embodiments, and the details will not be described again in this specification.
[0338] For a clearer syntax table, please refer to Figure 16. Figure 16 shows the merge data syntax table.
[0339] It can be seen that the syntax table or bitstream includes merge_subblock_flag[x0][y0], which may correspond to indication information that may be used to indicate that a block-based candidate motion information list or a subblock-based candidate motion information list is used for the current block in the present invention.
[0340] The difference between embodiment 2 and the current technology is as follows: multiple types of candidate motion information are inserted into different candidate motion information lists, the bitstream is parsed to obtain the index information of the optimal candidate motion information, and the current block is decoded according to the corresponding motion information. According to embodiment 2, the block-based candidate motion information list and the sub-block-based candidate motion information list can be distinguished from each other. This effectively reduces the transmission cost of the optimal candidate motion information.
[0341] Embodiment 3 (Encoder side) Brief description: list0 and list1 are configured with various motion information list configuration modes for a current block (Block). list0 is a candidate motion vector list used for a current block when the current block is predicted by using a block as a basic prediction unit. list1 is a candidate motion vector list used for a current block when the current block is predicted by using a sub-block as a basic prediction unit. The current block may be divided into multiple sub-blocks, and each sub-block may be in the shape of a square or a rectangle. The sub-blocks may be, for example, but not limited to, 4×4, 8×8, or 4×8 in size. list0 and list1 include candidate motion information. The candidate motion information includes motion vectors, prediction directions, reference indexes, etc. In short, list0 and list1 are configured with various motion information list configuration modes applicable to the features of the current block.
[0342] For example, the block-based list0 includes the HEVC mode, the non-adjacent mode, the ATMVP mode, or the STMVP mode, The subblock-based list1 includes an AFFINE mode (including a motion model-based affine model merging mode or a control point-based composite merging mode) and a planar mode.
[0343] In a particular implementation process, list0 may include one or more of the candidate motion vector derivation modes, such as HEVC mode, non-adjacent mode, ATMVP mode, and STMVP mode. For example, in another embodiment, list0 may alternatively include only ATMVP mode. list1 may include one or more of the candidate motion vector derivation modes, such as AFFINE mode and planar mode. In this application, multiple modes may be used for explanation.
[0344] S31: Construct a first candidate motion information list (List0) for the current coding block.
[0345] A particular implementation may be performed by using a method the same as or similar to the method in S31.1:S11.1.
[0346] A particular implementation may be performed by using a method the same as or similar to the method in S31.2:S11.2.
[0347] A particular implementation may be performed by using a method the same as or similar to the method in S31.3:S12.3.
[0348] Please note that in the present invention, the sequence of adding candidate motion information in S31.1 and S31.2 into the list is not limited to S31. The motion information in S31.1 can be added before the motion information in S31.2, or the motion information in S31.2 can be added before the motion information in S31.1, or the motion information in S31.1 and the motion information in S31.2 can be added alternately into the list.
[0349] S32: A second candidate motion information list (List1) of the current coding block is constructed.
[0350] A particular implementation may be performed by using a method the same as or similar to the method in S32.1:S12.1.
[0351] S32.2: A particular implementation may be performed by using a method the same as or similar to the method in S12.2.
[0352] A particular implementation may be performed by using methods the same as or similar to those in S32.3:S12.4.
[0353] Please note that in the present invention, the sequence of adding candidate motion information in S32.1, S32.2, and S32.3 into the list is not limited to S32. Candidate motion information may be added in a specific sequence, or different types of motion information may be added alternately into the list, or one or more of the candidate motion information in S32.1, S32.2, and S32.3 may be added into the list.
[0354] S33: Select the best candidate motion information from the two lists, where a specific implementation may be performed by using the same or similar method as in S13.
[0355] S34: Perform motion compensation on the current block based on the best candidate motion information obtained in S33 to obtain a sample predictor of the block. A specific implementation may be performed by using the same or similar method as the method in S14.
[0356] It should be understood that list0 and list1 may be swapped.
[0357] The difference between embodiment 3 and the current technology is as follows: various candidate motion vectors are inserted into different candidate motion vector lists, the bitstream is parsed to obtain the index information of the optimal candidate motion information, and the current block is decoded according to the corresponding motion information. According to embodiment 3, the model-based sub-block (SUB-BLOCK)-based candidate motion information list and other candidate motion information can be distinguished from each other. This effectively reduces the transmission cost of the optimal candidate motion information.
[0358] Embodiment 4 (Decoder side) Brief description: the candidate motion information of a current block (Block) and the candidate motion information of a current sub-block (Sub-BLOCK) can be inserted (or configured) into list0 and list1, respectively, when obtaining a mode of the candidate motion information.
[0359] The block-based list0 includes the HEVC mode, the non-adjacent mode, the ATMVP mode, and the STMVP mode.
[0360] The subblock-based list1 includes an AFFINE mode (including a motion model-based affine model merging mode or a control point-based composite merging mode) and a planar mode.
[0361] In a particular implementation process, list0 may include one or more of the candidate motion vector derivation modes, such as HEVC mode, non-adjacent mode, ATMVP mode, and STMVP mode. For example, in another embodiment, list0 may include only ATMVP mode. list1 may include one or more of the candidate motion vector derivation modes, such as AFFINE mode and planar mode. In this application, multiple modes may be used for description.
[0362] S41: Parse the bitstream to obtain index information of the best candidate motion information.
[0363] In particular, the bitstream is parsed to obtain an index (e.g., list-idx) of a candidate motion information list containing the best candidate motion information, and an index value (e.g., mv-index) of the location of the best candidate motion information in the list.
[0364] S42: Construct a candidate motion information list based on the candidate motion information list index.
[0365] When list-idx=0, a specific implementation may be performed by using the same or similar method as in S31. For example, the block-based candidate motion information list is configured with the modes in S31.1, S31.2, and / or S31.3. Correspondingly, in another example, the block-based candidate motion information list is configured with the modes in S11.1, S11.2, and / or S12.3.
[0366] When list-idx=1, the model-based sub-block-based candidate motion information list is configured with the modes in S32.1, S32.2, and / or S32.3. Correspondingly, in another example, the sub-block-based candidate motion information list is configured with the modes in S12.1, S12.2, and / or S12.4.
[0367] S43: Determine optimal candidate motion information based on the index information.
[0368] In particular, the best candidate motion information is determined from the list based on the list-idx and the mv-index.
[0369] S44: Perform motion compensation on the current block based on the best candidate motion information obtained in S43 to obtain a sample predictor of the block.
[0370] The difference between embodiment 4 and the current technology is as follows: different types of candidate motion information are inserted into different candidate motion information lists, the bitstream is parsed to obtain the index information of the optimal candidate motion information, and the current block is decoded according to the corresponding motion information. According to embodiment 4, the model-based sub-block (SUB-BLOCK)-based candidate motion information list and other candidate motion information can be distinguished from each other. This effectively reduces the transmission cost of the optimal candidate motion information.
[0371] Embodiment 5 (Encoder side) It is determined whether the current coding block satisfies the preset condition. If the current coding block satisfies the preset condition, S51 and S52 are executed, or if the current coding block does not satisfy the preset condition, S51 is executed. Alternatively, if the current coding block satisfies the preset condition, S51 and S52 are executed, or if the current coding block does not satisfy the preset condition, S52 is executed.
[0372] The preset conditions may be as follows: (1) the width of the current coding block is greater than or equal to a threshold value (e.g., but not limited to, 4, 8, 16, or 32) and / or the height of the current coding block is greater than or equal to a threshold value (e.g., but not limited to, 4, 8, 16, or 32); or (2) The number of samples (width x height) of the current coding block is greater than or equal to a threshold value (e.g., 256).
[0373] The pre-configured conditions may be agreed upon by both the encoder and decoder sides, or may be specified by using a higher level syntax such as SPS or PPS.
[0374] S51: Construct a first candidate motion information list (List0) of the current coding block.
[0375] The first candidate motion information list is constructed by using a corresponding method, for example, the method in S11 in embodiment 1 or S31 in embodiment 3. The details will not be described again in this specification.
[0376] S52: A second candidate motion information list (List1) of the current coding block is constructed.
[0377] The second candidate motion information list is constructed by using a corresponding method, for example, the method in S12 in embodiment 1 or S32 in embodiment 3. The details will not be described again in this specification.
[0378] S53: The best candidate motion information is selected.
[0379] If the current coding block satisfies the preset condition, the best candidate motion information is determined from the two candidate motion information lists according to the rate-distortion cost criterion as the motion information of the current coding block.Then, the index (for example, list-idx) of the candidate motion information list containing the best candidate motion information and the index value (for example, mv-idx) of the location of the best candidate motion information in the list are transferred to the decoder side.
[0380] If the current coding block does not meet the preset condition, the best candidate motion information is determined from one candidate motion information list according to the rate distortion cost criterion as the motion information of the current coding block.Then, the index value (for example, mv-idx) of the location of the best candidate motion information in the candidate motion information list is transferred to the decoder side.
[0381] S54: Perform motion compensation on the current block based on the best candidate motion information obtained in S53 to obtain a sample predictor of the block. A specific implementation may be performed by using the same or similar method as in S14 or S34.
[0382] The difference between embodiment 5 and the current technology is as follows: various candidate motion vectors are inserted into different candidate motion vector lists, the bitstream is parsed to obtain the index information of the best candidate motion information, and the current block is decoded according to the corresponding motion information. In addition, various motion information lists will be configured based on a preset condition, and the candidate list used is conditionally parsed according to the characteristics of the current coding block, so that the amount of bits required to indicate the candidate list can be reduced.
[0383] Referring to embodiment 5, the encoding method procedure can be obtained as follows:
[0384] S161: If the size of the current block meets the preset sample quantity, construct a first list.
[0385] S162: Construct a second list, where the first list is a block-based candidate motion information list, the second list is a sub-block-based candidate motion information list, and the inter prediction mode used for the current block is a merge mode.
[0386] S163: Determine optimal candidate motion information from the first list and the second list.
[0387] S164: Predict the current block based on the optimal motion information.
[0388] Optionally, prior to S161, the method further comprises: It may further include determining whether the size of the current block meets a preset sample quantity.
[0389] Optionally, it is determined whether either the width or height of the current coding block is greater than or equal to a threshold, for example, whether the width and / or height is greater than or equal to 8.
[0390] If the size of the current block does not meet the preset sample quantity, the method further includes:
[0391] S165: Construct a first list, where the first list is a block-based candidate motion information list, and the inter prediction mode used for the current block is a merge mode.
[0392] S166: Determine the best candidate motion information from the first list.
[0393] S167: Predict the current block based on the optimal motion information.
[0394] It should be understood that S165-S167 may be implemented as an encoding method independent of S161-S164.
[0395] Embodiment 6 (Decoder side) S61: Parse the bitstream based on a preset condition to obtain index information of the best candidate motion information.
[0396] The preset conditions may be as follows: (1) the width of the current coding block is greater than or equal to a threshold value (e.g., but not limited to, 4, 8, 16, or 32) and / or the height of the current coding block is greater than or equal to a threshold value (e.g., but not limited to, 4, 8, 16, or 32); or (2) The number of samples (width x height) of the current coding block is greater than or equal to a threshold value (e.g., 256).
[0397] The pre-configured conditions may be agreed upon by both the encoder and decoder sides, or may be specified by using a higher level syntax such as SPS or PPS.
[0398] When the current coding block does not satisfy the preset conditions (which may be understood as none of the preset conditions being satisfied), the index information of the motion information is not parsed (only block-based motion information is used). In this case, list0 (list-idx=0 in a specific implementation) is used by default, and the index value (mv-index) of the location in list0 is parsed. In particular, only the index value (mv-index) of the location in list list0 may be parsed.
[0399] When the current coding block satisfies a condition (which may be understood as any of the pre-set conditions being met), the bitstream is parsed to obtain an index (e.g., list-idx, where the value of list-idx may be 0 or 1) of a candidate motion information list containing the optimal candidate motion information, and an index value (e.g., mv-index) of the location of the optimal candidate motion information in the candidate motion information list is obtained.
[0400] S62: Construct a candidate motion information list based on the candidate motion information list index.
[0401] In particular, the list may be constructed by using the corresponding method in embodiment 2 or embodiment 4. In particular, the list may be constructed by using the same or similar method as the method in S22 or S42. The details will not be described again in this specification.
[0402] S63: Determine optimal candidate motion information based on the index information.
[0403] In particular, the best candidate motion information is determined from the list based on list-idx and mv-index. In particular, the best candidate motion information may be determined by using the same or similar method as in S23 or S43. The details are not described again in this specification.
[0404] S64: Perform motion compensation on the current coding block based on the best candidate motion information obtained in S63 to obtain a sample predictor of the block. A specific implementation may be performed by using the same or similar method as in S24 or S44.
[0405] The difference between embodiment 6 and the current technology is as follows: various candidate motion vectors are inserted into different candidate motion vector lists, the bitstream is parsed to obtain the index information of the best candidate motion information, and the current coding block is decoded based on the corresponding motion information. In addition, various motion information lists will be configured based on a preset condition, and the candidate list used is conditionally parsed based on the characteristics of the current coding block, so that the amount of bits required to indicate the candidate list can be reduced.
[0406] Referring to embodiment 6, a decoding method procedure can be obtained. See Figure 17. The method includes the following steps:
[0407] S171: If the size of the current block meets a preset number of samples, obtain an identifier used to determine a candidate motion information list including optimal candidate motion information for the current block, and obtain an index of the optimal candidate motion information in the candidate motion information list, where the inter prediction mode used for the current block is merge mode.
[0408] Optionally, see S61 for specific implementations.
[0409] S172: Construct a candidate motion information list based on the identifier, and construct a block-based candidate motion information list when the identifier is a first feature value, or construct a sub-block-based candidate motion information list when the identifier is a second feature value.
[0410] Optionally, see S62 for specific implementations.
[0411] S173: Based on the index, determine the optimal motion information from the constructed candidate motion information list.
[0412] Optionally, see S63 for specific implementations.
[0413] S174: Predict the current block based on the optimal motion information.
[0414] Optionally, see S64 for specific implementations.
[0415] Before S171, the method further includes determining whether the size of the current block satisfies a preset condition or a preset sample quantity.
[0416] Optionally, it is determined whether either the width or height of the current coding block is greater than or equal to a threshold, for example, whether the width and / or height is greater than or equal to 8.
[0417] If the size of the current block does not meet the preset sample quantity, the method further includes:
[0418] S175: Construct a first list, where the first list is a block-based candidate motion information list, and the inter prediction mode used for the current block is a merge mode.
[0419] S176: Determine the best candidate motion information from the first list.
[0420] S177: Predict the current block based on the optimal motion information.
[0421] It should be understood that S175-S177 may be implemented as an encoding method independent of S171-S174.
[0422] Embodiment 7 (Decoder side) S71: Parse the bitstream based on a preset condition to obtain index information of the best candidate motion information.
[0423] When the first preset condition is met, the index of the best candidate motion information list is 0 (only block-based motion information is used). In other words, list0 (which may also be indicated by list-idx=0) is used.
[0424] When the second preset condition is met, the index of the best candidate motion information list is 1 (only sub-block-based motion information is used). In other words, list1 (which may also be indicated by list-idx=1) is used.
[0425] When neither the first preset condition nor the second preset condition is satisfied, the bitstream is parsed to obtain an index (e.g., list-idx) of a candidate motion information list that includes the best candidate motion information, and whether list0 or list1 should be used is determined based on list-idx. Finally, the index value (e.g., mv-index) of the location of the best candidate motion information in the corresponding list is parsed.
[0426] The first pre-set condition may be as follows: (1) the width of the current coding block is less than a first threshold (e.g., 16) and / or the height of the current coding block is less than a first threshold (e.g., 16), or (2) The number of samples (width x height) of the current coding block is less than a first threshold (eg, 256).
[0427] The first pre-configured condition may be agreed upon by both the encoder and decoder sides, or may be specified by using a higher level syntax such as SPS or PPS.
[0428] The second preset condition may be as follows: (1) the width of the current coding block is greater than or equal to a second threshold (e.g., 64) and / or the height of the current coding block is greater than or equal to a second threshold (e.g., 64); or (2) The number of samples (width x height) of the current coding block is greater than or equal to a second threshold (eg, 1024).
[0429] The second pre-configured condition may be agreed upon by both the encoder and decoder sides, or may be specified by using a higher level syntax such as SPS or PPS.
[0430] The second threshold is greater than the first threshold.
[0431] S72: Construct a candidate motion information list based on the candidate motion information list index.
[0432] In particular, the list may be constructed by using the corresponding method in embodiment 2, embodiment 4, or embodiment 6. In particular, the list may be constructed by using the same or similar method as the method in S22, S42, or S62. The details will not be described again in this specification.
[0433] S73: Determine optimal candidate motion information based on the index information.
[0434] In particular, the best candidate motion information is determined from the list based on list-idx and mv-index. In particular, the best candidate motion information may be determined by using the same or similar method as in S23, S43, or S63. The details are not described again in this specification.
[0435] S74: Perform motion compensation on the current coding block based on the best candidate motion information obtained in S73 to obtain a sample predictor of the block. A specific implementation may be performed by using the same or similar method as in S24, S44, or S64.
[0436] The difference between embodiment 7 and the current technology is as follows: various candidate motion vectors are inserted into different candidate motion vector lists, the bitstream is parsed to obtain the index information of the best candidate motion information, and the current coding block is decoded according to the corresponding motion information. In addition, various motion information lists are constructed based on a preset condition, and the candidate list used is conditionally parsed based on the characteristics of the current coding block, so that the amount of bits required to indicate the candidate list can be reduced.
[0437] One embodiment of the present application provides an apparatus 1800. See FIG. 18. The apparatus 1800 includes: An acquisition module 1801 configured to acquire index information of optimal candidate motion information of a current block; A configuration module 1802 configured to configure a candidate motion information list based on index information, where a mode of obtaining a motion vector included in the candidate motion information list varies with a field of the index information; a determining module 1803 configured to determine an optimal motion vector from the candidate motion information list based on the index information; and a prediction module 1804 configured to predict the current block based on the optimal motion vector.
[0438] In detail, the acquisition module 1801 is configured to execute the corresponding method in S21 and an equivalent method that can be used for partial replacement. The configuration module 1802 is configured to execute the corresponding method in S22 and an equivalent method that can be used for partial replacement. The determination module 1803 is configured to execute the corresponding method in S23 and an equivalent method that can be used for partial replacement. The prediction module 1804 is configured to execute the corresponding method in S24 and an equivalent method that can be used for partial replacement.
[0439] In detail, the acquisition module 1801 is configured to execute the corresponding method in S41 and an equivalent method that can be used for partial replacement. The configuration module 1802 is configured to execute the corresponding method in S42 and an equivalent method that can be used for partial replacement. The determination module 1803 is configured to execute the corresponding method in S43 and an equivalent method that can be used for partial replacement. The prediction module 1804 is configured to execute the corresponding method in S44 and an equivalent method that can be used for partial replacement.
[0440] In detail, the acquisition module 1801 is configured to execute the corresponding method in S51 and an equivalent method that can be used for partial replacement. The configuration module 1802 is configured to execute the corresponding method in S52 and an equivalent method that can be used for partial replacement. The determination module 1803 is configured to execute the corresponding method in S53 and an equivalent method that can be used for partial replacement. The prediction module 1804 is configured to execute the corresponding method in S54 and an equivalent method that can be used for partial replacement.
[0441] In detail, the acquisition module 1801 is configured to execute the corresponding method in S61 and an equivalent method that can be used for partial replacement. The configuration module 1802 is configured to execute the corresponding method in S62 and an equivalent method that can be used for partial replacement. The determination module 1803 is configured to execute the corresponding method in S63 and an equivalent method that can be used for partial replacement. The prediction module 1804 is configured to execute the corresponding method in S64 and an equivalent method that can be used for partial replacement.
[0442] In detail, the acquisition module 1801 is configured to execute the corresponding method in S71 and an equivalent method that can be used for partial replacement. The configuration module 1802 is configured to execute the corresponding method in S72 and an equivalent method that can be used for partial replacement. The determination module 1803 is configured to execute the corresponding method in S73 and an equivalent method that can be used for partial replacement. The prediction module 1804 is configured to execute the corresponding method in S74 and an equivalent method that can be used for partial replacement.
[0443] In addition, the acquisition module 1801 is configured to perform a method corresponding to S141, S151, or S171 and an equivalent method that may be used for partial replacement of S141, S151, or S171. The configuration module 1802 is configured to perform a method corresponding to S142, S152, or S172 and an equivalent method that may be used for partial replacement of S142, S152, or S172. The determination module 1803 is configured to perform a method corresponding to S143, S153, or S173 and an equivalent method that may be used for partial replacement of S143, S153, or S173. The prediction module 1804 is configured to perform a method corresponding to S144, S154, or S174 and an equivalent method that may be used for partial replacement of S144, S154, or S174.
[0444] An embodiment of the present application provides an encoding device 19. See Fig. 19. The device may be a multi-purpose coding device, and includes a non-volatile memory and a processor coupled to each other. The processor calls the program code stored in the memory to perform methods such as S11, S12, S13, and S14, and equivalent methods.
[0445] One embodiment of the present application provides an encoding device 19, including a non-volatile memory and a processor coupled to each other. The processor invokes program codes stored in the memory to perform methods such as S31, S32, S33, and S34, and equivalent methods.
[0446] One embodiment of the present application provides an encoding device 19, including a non-volatile memory and a processor coupled to each other. The processor invokes program codes stored in the memory to perform methods such as S51, S52, S53, and S54, and equivalent methods.
[0447] One embodiment of the present application provides a decoding device 19 (where the device may be a coding device), including a non-volatile memory 1901 and a processor 1902 coupled together. The processor calls program codes stored in the memory to perform methods such as S21, S22, S23, and S24, and equivalent methods.
[0448] One embodiment of the present application provides a decoding device 19, including a non-volatile memory 1901 and a processor 1902 coupled to each other. The processor invokes program codes stored in the memory to perform methods such as S41, S42, S43, and S44, and equivalent methods.
[0449] One embodiment of the present application provides a decoding device 19, including a non-volatile memory 1901 and a processor 1902 coupled to each other. The processor invokes program codes stored in the memory to perform methods such as S61, S62, S63, and S64, and equivalent methods.
[0450] One embodiment of the present application provides a decoding device 19, including a non-volatile memory 1901 and a processor 1902 coupled to each other. The processor invokes program codes stored in the memory to perform methods such as S71, S72, S73, and S74, and equivalent methods.
[0451] Coding device 19 may further include a display 1903 configured to display video pictures.
[0452] An embodiment of the present application provides a computer-readable storage medium. The computer-readable storage medium stores program code. The program code includes instructions used to execute some or all of steps S11-S14, S21-S24, S31-S34, S41-S44, S51-S54, S61-S64, and / or S71-S74.
[0453] One embodiment of the present application provides a computer program product, which, when run on a computer, causes the computer to execute some or all of steps S11-S14, S21-S24, S31-S34, S41-S44, S51-S54, S61-S64, and / or S71-S74.
[0454] It should be understood that the explanations and descriptions of some technical features in the method embodiments are also applicable to apparatus embodiments, encoding devices, decoding devices, computer programs, storage media, and the like.
[0455] Those skilled in the art can appreciate that the functions described with reference to the various exemplary logical blocks, modules, and algorithm steps disclosed and described herein may be implemented by hardware, software, firmware, or any combination thereof. When implemented by software, the functions described with reference to the exemplary logical blocks, modules, and steps may be stored in or transmitted via a computer-readable medium as one or more instructions or codes and executed by a hardware-based processing unit. The computer-readable medium may include a computer-readable storage medium, which corresponds to a tangible medium such as a data storage medium, or a communication medium, which includes any medium that facilitates the transfer (e.g., via a communication protocol) of a computer program from one place to another. In this manner, the computer-readable medium may generally correspond to (1) a non-transitory tangible computer-readable storage medium, or (2) a communication medium, such as a signal or carrier. The data storage medium may be any available medium that can be accessed by one or more computers or one or more processors to retrieve instructions, codes, and / or data structures to implement the techniques described in this application. A computer program product may include a computer-readable medium.
[0456] By way of example and not limitation, such computer-readable storage media may include RAM, ROM, EEPROM, CD-ROM or other compact disk storage, magnetic disk storage or other magnetic storage, flash memory, or any other medium that can be used to store desired program code in the form of instructions or data structures and that can be accessed by a computer. In addition, any connection is properly referred to as a computer-readable medium. For example, if instructions are transmitted from a website, server, or another remote source over coaxial cable, fiber optic, twisted pair, digital subscriber line (DSL), or wireless technologies such as infrared, radio, and microwave, the coaxial cable, fiber optic cable, twisted pair, DSL, or wireless technologies such as infrared, radio, and microwave are included within the definition of media. However, it should be understood that computer-readable storage media and data storage media do not include connections, carriers, signals, or other transitory media, but rather refer to non-transitory tangible storage media in practice. As used herein, disk and disc include compact disc (CD), laser disc, optical disc, digital versatile disc (DVD), and Blu-ray disc. Disks typically reproduce data magnetically, while discs reproduce data optically using lasers. Combinations of the above should also be included within the scope of computer-readable media.
[0457] The instructions may be executed by one or more processors, such as one or more digital signal processors (DSPs), general-purpose microprocessors, application specific integrated circuits (ASICs), field programmable logic arrays (FPGAs), or other equivalent integrated or discrete logic circuits. Thus, the term "processor" as used herein may refer to any of the above structures or any other structures suitable for implementing the techniques described herein. In addition, in some aspects, the functionality described with reference to the exemplary logic blocks, modules, and steps described herein may be provided in dedicated hardware and / or software modules configured for encoding and decoding, or may be incorporated into a combined codec. In addition, the techniques may be implemented entirely in one or more circuits or logic elements.
[0458] The techniques in this application may be implemented in a variety of apparatuses or devices, including a wireless handset, an integrated circuit (IC), or a set of ICs (e.g., a chipset). Various components, modules, or units are described in this application to highlight functional aspects of an apparatus configured to perform the disclosed techniques, but are not necessarily implemented by different hardware units. In practice, as described above, the various units may be combined into a codec hardware unit in combination with appropriate software and / or firmware, or may be provided by interoperable hardware units (including one or more processors as described above).
[0459] The above description is merely an example of a specific implementation of the present application, and is not intended to limit the scope of protection of the present application. Any variation or replacement that can be easily found by a person skilled in the art within the technical scope disclosed in this application shall fall within the scope of protection of the present application. Therefore, the scope of protection of the present application shall be subject to the scope of protection of the claims. [Explanation of symbols]
[0460] 19 Encoding devices, decoding devices, coding devices 1800 equipment 1801 Acquisition Module 1802 Configuration Module 1803 Decision Module 1804 Prediction Module 1901 Non-volatile memory 1902 Processor 1903 Display
Claims
1. 1. A method of decoding, comprising: Obtaining a configuration mode of a candidate motion information list comprising optimal candidate motion information of a current block, and obtaining an index of the optimal candidate motion information in the candidate motion information list, wherein the configuration mode of the candidate motion information list is a mode of constructing a block-based candidate motion information list or a mode of constructing a sub-block-based candidate motion information list; configuring the candidate motion information list in the configuration mode; determining an optimal motion information from the constructed list of candidate motion information based on the index; predicting the current block based on the optimal motion information; A method for providing the above.
2. The step of obtaining a configuration mode of a candidate motion information list comprising the optimal candidate motion information of the current block includes: obtaining an identifier used to determine the candidate motion information list, wherein when an inter prediction mode used for the current block is a merge mode and the identifier is a first feature value, the configuration mode of the candidate motion information list is the mode of configuring the block-based candidate motion information list, or when the identifier is a second feature value, the configuration mode of the candidate motion information list is the mode of configuring the sub-block-based candidate motion information list. The method of claim 1.
3. The sub-block based candidate motion information list comprises: a candidate motion information list configured with at least one sub-block based merge mode of affine model merge, complex merge, or ATMVP; The method according to claim 1 or 2.
4. The method of claim 1 or 2, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
5. 5. The method of claim 1, wherein the width of the current block is greater than or equal to a threshold value and / or the height of the current block is greater than or equal to a threshold value.
6. 1. A method of decoding, comprising: obtaining an identifier used to determine a candidate motion information list comprising optimal candidate motion information for a current block, and obtaining an index of the optimal candidate motion information in the candidate motion information list, wherein an inter prediction mode used for the current block is a merge mode; constructing the candidate motion information list based on the identifier, where when the identifier is a first feature value, the candidate motion information list is a block-based candidate motion information list, or when the identifier is a second feature value, the candidate motion information list is a sub-block-based candidate motion information list; determining an optimal motion information from the constructed list of candidate motion information based on the index; predicting the current block based on the optimal motion information; A method for providing the above.
7. The method of claim 5 , wherein the sub-block based candidate motion information list comprises a candidate motion information list configured with at least one of the following sub-block based merge modes: affine model merge, complex merge, or ATMVP.
8. 8. The method of claim 6 or 7, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
9. 9. A method according to any one of claims 6 to 8, wherein the width of the current block is greater than or equal to a threshold and / or the height of the current block is greater than or equal to a threshold.
10. 1. A method of decoding, comprising: If the size of the current block meets a preset number of samples, obtaining an identifier used to determine a candidate motion information list comprising optimal candidate motion information of the current block, and obtaining an index of the optimal candidate motion information in the candidate motion information list, where the inter prediction mode used for the current block is a merge mode; constructing the candidate motion information list based on the identifier, where the identifier is a first feature value, constructing a block-based candidate motion information list, or the identifier is a second feature value, constructing a sub-block-based candidate motion information list; determining an optimal motion information from the constructed list of candidate motion information based on the index; predicting the current block based on the optimal motion information; A method for providing the above.
11. If the size of the current block does not satisfy the preset number of samples, constructing the block-based candidate motion information list and obtaining the index of the best candidate motion information in the candidate motion information list, where the inter prediction mode used for the current block is the merge mode; and determining the optimal motion information from the constructed candidate motion information list based on the obtained index; predicting the current block based on the optimal motion information; The method of claim 10, further comprising:
12. 12. The method of claim 10 or 11, wherein the sub-block based candidate motion information list comprises a candidate motion information list configured with at least one of the following sub-block based merge modes: affine model merge, complex merge, or ATMVP.
13. 13. The method of claim 10, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
14. 14. The method of claim 10, wherein the size of the current block fulfilling a preset quantity of samples comprises a width of the current block being greater than or equal to a threshold and / or a height of the current block being greater than or equal to a threshold.
15. A decoding device, comprising: an acquisition module configured to acquire a configuration mode of a candidate motion information list comprising optimal candidate motion information of a current block, and acquire an index of the optimal candidate motion information in the candidate motion information list, the configuration mode of the candidate motion information list being a mode of configuring a block-based candidate motion information list, or a mode of configuring a sub-block-based candidate motion information list; a configuration module configured to configure the candidate motion information list in the configuration mode; a determination module configured to determine an optimal motion information from the configured candidate motion information list based on the index; a prediction module configured to predict the current block based on the optimal motion information; An apparatus comprising:
16. The acquisition module: specifically configured to obtain an identifier used to determine the candidate motion information list, and when the inter prediction mode used for the current block is a merge mode and the identifier is a first feature value, the construction mode of the candidate motion information list is the mode of constructing the block-based candidate motion information list, or when the identifier is a second feature value, the construction mode of the candidate motion information list is the mode of constructing the sub-block-based candidate motion information list.
16. The apparatus of claim 15.
17. 17. The apparatus of claim 15 or 16, wherein the sub-block based candidate motion information list comprises a candidate motion information list configured with at least one of the following sub-block based merging modes: affine model merge, complex merge, or ATMVP.
18. 18. The apparatus of claim 15, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
19. 19. Apparatus according to any one of claims 15 to 18, wherein a width of the current block is greater than or equal to a threshold and / or a height of the current block is greater than or equal to a threshold.
20. A decoding device, comprising: an acquisition module configured to acquire an identifier used to determine a candidate motion information list comprising optimal candidate motion information for a current block, and to acquire an index of the optimal candidate motion information in the candidate motion information list, wherein an inter prediction mode used for the current block is a merge mode; and a configuration module configured to configure the candidate motion information list based on the identifier, where when the identifier is a first feature value, the candidate motion information list is a block-based candidate motion information list, or when the identifier is a second feature value, the candidate motion information list is a sub-block-based candidate motion information list; a determination module configured to determine an optimal motion information from the configured candidate motion information list based on the index; a prediction module configured to predict the current block based on the optimal motion information; An apparatus comprising:
21. 21. The apparatus of claim 20, wherein the sub-block based candidate motion information list comprises a candidate motion information list configured with at least one of the following sub-block based merge modes: affine model merge, complex merge, or ATMVP.
22. The apparatus of claim 20 or 21, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
23. 23. Apparatus according to any one of claims 20 to 22, wherein a width of the current block is greater than or equal to a threshold and / or a height of the current block is greater than or equal to a threshold.
24. A decoding device, comprising: An acquisition module configured to acquire an identifier of a candidate motion information list including optimal candidate motion information of the current block when the size of the current block meets a preset number of samples, and acquire an index of the optimal candidate motion information in the candidate motion information list, where an inter prediction mode used for the current block is a merge mode; and a construction module configured to construct the candidate motion information list based on the identifier, the construction module constructing a block-based candidate motion information list when the identifier is a first feature value, or constructing a sub-block-based candidate motion information list when the identifier is a second feature value; a determination module configured to determine an optimal motion information from the configured candidate motion information list based on the index; a prediction module configured to predict the current block based on the optimal motion information; An apparatus comprising:
25. The configuration module: and further particularly configured to configure the block-based candidate motion information list when the size of the current block does not satisfy the preset number of samples, and the inter prediction mode used for the current block is the merge mode.
25. The apparatus of claim 24.
26. 26. The apparatus of claim 24 or 25, wherein the sub-block based candidate motion information list comprises a candidate motion information list configured with at least one of the following sub-block based merging modes: affine model merge, complex merge, or ATMVP.
27. 27. The apparatus of claim 24, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
28. 28. The apparatus of claim 24, wherein a size of a current block fulfilling a preset quantity of samples comprises a width of the current block being greater than or equal to a threshold and / or a height of the current block being greater than or equal to a threshold.
29. 1. A method of decoding, comprising: parsing the bitstream to obtain a syntax element, the syntax element comprising at least an index of a best candidate motion information of a current block; determining based on the syntax element whether a first list or a second list should be constructed for the current block, the first list being a block-based candidate motion information list and the second list being a sub-block-based candidate motion information list; determining optimal motion information from the first list or the second list based on the index; predicting the current block based on the optimal motion information; A method for providing the above.
30. 30. The method of claim 29, wherein the sub-block based candidate motion information list comprises a candidate motion information list configured with at least one of the following sub-block based merge modes: affine model merge, complex merge, or ATMVP.
31. 30. The method of claim 29, wherein the sub-block based candidate motion information list comprises a candidate motion information list consisting of only a sub-block based merge mode of ATMVP.
32. 32. The method of claim 29, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
33. 32. The method of claim 29, wherein the candidate motion information in the first list comprises one or more of motion information of a spatially adjacent block to the top left of the current block, motion information of a spatially adjacent block to the left of the current block, motion information of a spatially adjacent block to the bottom left of the current block, motion information of a spatially adjacent block to the top right of the current block, or motion information of a spatially adjacent block to the right of the current block.
34. the syntax element comprises a list index, and the step of determining based on the syntax element whether to construct a first list or a second list for the current block comprises: obtaining a candidate motion information list index, when the list index is a first feature value, which indicates that the first list should be constructed for the current block, or when the list index is a second feature value, which indicates that the second list should be constructed for the current block.
34. The method of any one of claims 29 to 33.
35. 34. The method of claim 29, wherein the syntax element further comprises display information used to indicate that the block-based candidate motion information list is used for the current block, or display information used to indicate that the sub-block-based candidate motion information list is used for the current block.
36. 36. A method according to any one of claims 29 to 35, wherein the width of the current block is greater than or equal to a threshold and / or the height of the current block is greater than or equal to a threshold.
37. A decoding device, comprising: an acquisition module configured to parse the bitstream to obtain a syntax element, the syntax element comprising at least an index of a best candidate motion information of a current block; A configuration module configured to determine based on the syntax element whether a first list or a second list should be configured for the current block, where the first list is a block-based candidate motion information list and the second list is a sub-block-based candidate motion information list; and a determination module configured to determine optimal motion information from the first list or the second list based on the index; a prediction module configured to predict the current block based on the optimal motion information; An apparatus comprising:
38. 38. The apparatus of claim 37, wherein the sub-block based candidate motion information list comprises a candidate motion information list configured with at least one of the following sub-block based merge modes: affine model merge, complex merge, or ATMVP.
39. 38. The apparatus of claim 37, wherein the sub-block based candidate motion information list comprises a candidate motion information list consisting of only a sub-block based merge mode of ATMVP.
40. 40. The apparatus of claim 37, wherein the block-based candidate motion information list comprises a candidate motion information list configured in a merge mode defined according to the HEVC standard or an advanced version of the HEVC standard.
41. 41. The apparatus of claim 37, wherein the candidate motion information in the first list comprises one or more of motion information of a spatially adjacent block to the top left of the current block, motion information of a spatially adjacent block to the left of the current block, motion information of a spatially adjacent block to the bottom left of the current block, motion information of a spatially adjacent block to the top right of the current block, or motion information of a spatially adjacent block to the right of the current block.
42. the syntax element comprises a list index, and the configuration module further comprises: specifically configured to obtain a candidate motion information list index, when the list index is a first feature value, which indicates that the first list should be constructed for the current block, or when the list index is a second feature value, which indicates that the second list should be constructed for the current block.
42. Apparatus according to any one of claims 37 to 41.
43. 42. The apparatus of claim 37, wherein the syntax element further comprises: indication information used to indicate that the block-based candidate motion information list is used for the current block; or indication information used to indicate that the sub-block-based candidate motion information list is used for the current block.
44. 44. Apparatus according to any one of claims 37 to 43, wherein a width of the current block is greater than or equal to a threshold and / or a height of the current block is greater than or equal to a threshold.
45. 1. A method of encoding, comprising: constructing a first list, the first list being a block-based candidate motion information list; constructing a second list, the second list being a sub-block based candidate motion information list; determining best candidate motion information from the first list and the second list; predicting a current block based on the optimal motion information; A method for providing the above.
46. obtaining an identifier used to determine a candidate motion information list comprising optimal candidate motion information for a current block, and obtaining an index of the optimal candidate motion information in the candidate motion information list, wherein an inter prediction mode used for the current block is a merge mode, and the candidate motion information list is the first list when the identifier is a first feature value, or the candidate motion information list is the second list when the identifier is a second feature value; encoding said identifier and said index into a bitstream; 46. The method of claim 45, further comprising:
47. 1. A method of encoding, comprising: obtaining an identifier used to determine a candidate motion information list comprising optimal candidate motion information for a current block, and obtaining an index of the optimal candidate motion information in the candidate motion information list, wherein when an inter prediction mode used for the current block is a merge mode and the identifier is a first feature value, the candidate motion information list is a block-based candidate motion information list, or when the identifier is a second feature value, the candidate motion information list is a sub-block-based candidate motion information list; encoding said identifier and said index into a bitstream; A method for providing the above.
48. 1. A method of encoding, comprising: If the size of the current block meets the preset sample quantity, constructing a first list and a second list, the first list being a block-based candidate motion information list, the second list being a sub-block-based candidate motion information list, and an inter prediction mode used for the current block is a merge mode; determining best candidate motion information from the first list and the second list; predicting the current block based on the optimal motion information; A method for providing the above.
49. If the size of the current block satisfies the preset sample quantity, constructing the first list, the first list being the block-based candidate motion information list, and the inter prediction mode used for the current block being the merge mode; determining the best candidate motion information from the first list; predicting the current block based on the optimal motion information; 49. The method of claim 48, further comprising:
50. 1. An encoding device, comprising: A configuration module configured to configure a first list and a second list, the first list being a block-based candidate motion information list and the second list being a sub-block-based candidate motion information list; a determining module configured to determine an optimal candidate motion information from the first candidate motion information list and the second candidate motion information list; a prediction module configured to predict a current block based on the optimal motion information; An apparatus comprising:
51. an acquisition module configured to acquire an identifier used to determine a candidate motion information list comprising optimal candidate motion information for a current block, and to acquire an index of the optimal candidate motion information in the candidate motion information list, wherein an inter prediction mode used for the current block is a merge mode, and the candidate motion information list is the first list when the identifier is a first feature value, or the candidate motion information list is the second list when the identifier is a second feature value; an encoding module configured to encode the identifier and the index into a bitstream; 51. The apparatus of claim 50, further comprising:
52. 1. An encoding device, comprising: an acquisition module configured to acquire an identifier used to determine a candidate motion information list comprising optimal candidate motion information for a current block, and to acquire an index of the optimal candidate motion information in the candidate motion information list, wherein when an inter prediction mode used for the current block is a merge mode and the identifier is a first feature value, the candidate motion information list is a block-based candidate motion information list, or when the identifier is a second feature value, the candidate motion information list is a sub-block-based candidate motion information list; an encoding module configured to encode the identifier and the index into a bitstream; An apparatus comprising:
53. 1. An encoding device, comprising: A configuration module configured to configure a first list and a second list when a size of a current block meets a preset number of samples, the first list being a block-based candidate motion information list, the second list being a sub-block-based candidate motion information list, and an inter-prediction mode used for the current block being a merge mode; a determination module configured to determine an optimal candidate motion information from the first list and the second list; a prediction module configured to predict the current block based on the optimal motion information; An apparatus comprising:
54. The configuration module: and further configured to configure the first list when the size of the current block satisfies the preset number of samples, the first list being the block-based candidate motion information list, and the inter prediction mode used for the current block being the merge mode.
54. The apparatus of claim 53.
55. A video coding device comprising a non-volatile memory and a processor coupled to each other, the processor calling program code stored in the memory to perform a method according to any one of claims 1 to 14, 29 to 36, or 45 to 49.
56. 50. A computer readable storage medium having a computer program stored thereon, the computer program, when run on a processor, performing a method according to any one of claims 1 to 14, 29 to 36, or 45 to 49.