Angular mode inter prediction method, encoder and storage medium

By constructing a candidate neighbor block list and finding valid angle directions, and using the motion information of neighbor blocks to modify the motion information of unavailable neighbor blocks, the problem of high computational overhead in inter-frame prediction in angle mode is solved, thus improving video coding efficiency.

CN119031142BActive Publication Date: 2026-05-08ZHEJIANG DAHUA TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG DAHUA TECH CO LTD
Filing Date
2020-07-20
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Existing angle-based inter-frame prediction has excessive computational overhead in video coding, resulting in low efficiency.

Method used

Construct a candidate neighbor list, distinguish between usable and unusable neighbor blocks, determine the effective angle direction by deduplication of motion information, modify the motion information of unusable neighbor blocks using the motion information of neighbor blocks in the effective angle direction, and calculate the predicted value of the current block.

Benefits of technology

By reducing unnecessary computations on unavailable neighboring blocks, the overall computational overhead is reduced, and the efficiency of video coding is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119031142B_ABST
    Figure CN119031142B_ABST
Patent Text Reader

Abstract

The application discloses an angular mode inter prediction method and related device. The method comprises: constructing a candidate neighbor block list for a current block, the candidate neighbor block list comprising neighbor blocks of the current block in multiple angular directions, wherein the coded neighbor blocks using inter prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for the unavailable neighbor blocks; performing motion information duplication checking on the neighbor blocks in each angular direction, and the angular directions subjected to the duplication checking are effective angular directions; modifying the motion information of the unavailable neighbor blocks in the effective angular directions by using the motion information of reference blocks of the unavailable neighbor blocks in the effective angular directions; and calculating a prediction value of the current block by using the motion information of the available neighbor blocks and / or the unavailable neighbor blocks in each effective angular direction. In this way, the application can reduce the calculation overhead in the coding process.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of video coding technology, and in particular to an angle-mode inter-frame prediction method, encoder, and storage medium. Background Technology

[0002] Video coding technology can compress videos to reduce their data size, network bandwidth during transmission, and storage space. Video coding modes can include inter-frame prediction mode and intra-frame prediction mode.

[0003] Taking inter-frame prediction as an example, inter-frame prediction utilizes the highly correlated redundant information in the reference frame to predict the information of the current frame. Inter-frame prediction modes can be categorized in many ways, such as inter-frame motion vector angle prediction (MVAP), temporal motion vector prediction, spatial motion vector prediction, and historical motion vector prediction.

[0004] Taking the inter-frame motion vector angle prediction mode as an example, the inter-frame motion vector angle prediction mode can also be called angle mode inter-frame prediction. The so-called inter-frame motion vector angle prediction means that the motion information of the neighboring blocks in multiple angle directions of the current block (the block to be predicted in the current frame) is used as the motion information of the current block, and the rate-distortion cost of the current block is calculated when the motion information of the neighboring blocks in different angle directions is used as the motion information of the current block. Finally, the motion information of the neighboring block in the angle direction with the smallest rate-distortion cost is used as the motion information of the current block, and then the predicted value of the current block is obtained through the motion information of the current block.

[0005] However, existing angle-mode inter-frame prediction requires significant computational overhead. Summary of the Invention

[0006] This application provides an angle-mode inter-frame prediction method, encoder, and storage medium, which can solve the problem of high computational overhead required for existing angle-mode inter-frame prediction.

[0007] To address the aforementioned technical problems, this application provides a technical solution: an angle-mode inter-frame prediction method, comprising: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on neighbor blocks in each angle direction, and determining the angle direction through which deduplication occurs as the valid angle direction; modifying the motion information of unavailable neighbor blocks in the valid angle direction using the motion information of reference blocks of unavailable neighbor blocks in the valid angle direction; and calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction.

[0008] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, which includes: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for performing motion information deduplication on neighbor blocks in each angle direction, and the angle direction that passes the deduplication is the valid angle direction; a modification module for modifying the motion information of unavailable neighbor blocks in the valid angle direction using the motion information of reference blocks of unavailable neighbor blocks in the valid angle direction; and a calculation module for calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction.

[0009] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction method, which includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; if the temporal co-location block of the unavailable neighbor block is available, then the motion information of the unavailable neighbor block is set using the motion information of the temporal co-location block, otherwise the initial value is set to the motion information of the unavailable neighbor block; performing motion information deduplication on the neighbor blocks in each angle direction, and the angle direction through deduplication is the valid angle direction; modifying the motion information of the available neighbor blocks with the initial motion information using the motion information of the reference block of the unavailable neighbor block with the initial motion information; calculating the prediction value of the current block using the motion information of the available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction respectively.

[0010] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, comprising: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angular directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks using motion information of temporal co-location blocks when temporal co-location blocks of unavailable neighbor blocks are available, and for setting initial values ​​of motion information of unavailable neighbor blocks when temporal co-location blocks of unavailable neighbor blocks are unavailable; a deduplication module for performing motion information deduplication on neighbor blocks in each angular direction, and determining the angular direction through which deduplication occurs as the valid angular direction; a modification module for modifying the motion information of available neighbor blocks with initial motion information using motion information of reference blocks of unavailable neighbor blocks with initial motion information; and a calculation module for calculating the prediction value of the current block using motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angular direction.

[0011] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction apparatus, the apparatus comprising: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angular directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; selecting at least one pair of neighbor blocks in each angular direction according to the size of the current block for motion information deduplication, the angular direction through deduplication being the valid angular direction; modifying the motion information of available neighbor blocks using the motion information of reference blocks of unavailable neighbor blocks; and calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angular direction respectively.

[0012] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, which includes: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angular directions, wherein the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for selecting at least one pair of neighbor blocks in each angular direction based on the size of the current block to perform motion information deduplication, and the angular direction through deduplication is the valid angular direction; a modification module for modifying the motion information of available neighbor blocks using the motion information of reference blocks of unavailable neighbor blocks; and a calculation module for calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angular direction.

[0013] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction method, which includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on neighbor blocks in each angle direction, and determining the angle direction that passes the deduplication as a valid angle direction, wherein if the angle direction meets a first condition, at least one deduplication is added; modifying the motion information of unavailable neighbor blocks using the motion information of reference blocks of unavailable neighbor blocks; and calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction.

[0014] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, which includes: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for performing motion information deduplication on neighbor blocks in each angle direction, wherein the angle direction that passes the deduplication is a valid angle direction, wherein if the angle direction meets a first condition, at least one deduplication is added; a modification module for modifying the motion information of unavailable neighbor blocks using the motion information of a reference block of the unavailable neighbor blocks; and a calculation module for calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction.

[0015] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction method, which includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on neighbor blocks in each angle direction, and determining the angle direction through which deduplication is performed as the valid angle direction, wherein if at least two of the horizontal, vertical, and upward horizontal deduplication results satisfy a second condition, then at least one deduplication for the upward horizontal direction is reduced; modifying the motion information of unavailable neighbor blocks using the motion information of reference blocks of unavailable neighbor blocks; and calculating the prediction value of the current block using the motion information of available and / or unavailable neighbor blocks in each valid angle direction.

[0016] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, comprising: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angular directions, wherein the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for performing motion information deduplication on neighbor blocks in each angular direction, wherein the angular direction of deduplication is a valid angular direction, wherein if at least two of the horizontal, vertical, and horizontal-upward deduplication results satisfy a second condition, then at least one deduplication of the horizontal-upward direction is reduced; a modification module for modifying the motion information of unavailable neighbor blocks using the motion information of a reference block of the unavailable neighbor blocks; and a calculation module for calculating the prediction value of the current block using the motion information of available and / or unavailable neighbor blocks in each valid angular direction.

[0017] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction method, which includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on neighbor blocks in each angle direction, the angle direction through deduplication is the valid angle direction, the deduplication includes determining whether the image sequence index of the reference frames of at least one pair of selected neighbor blocks is the same and whether the motion is the same; modifying the motion information of unavailable neighbor blocks using the motion information of the reference blocks of unavailable neighbor blocks; calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction respectively.

[0018] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, which includes: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for performing motion information deduplication on neighbor blocks in each angle direction, wherein the angle direction through deduplication is the valid angle direction, and the deduplication includes determining whether the image sequence index of the reference frames of at least one pair of selected neighbor blocks is the same and whether the motion is the same; a modification module for modifying the motion information of unavailable neighbor blocks using the motion information of the reference blocks of unavailable neighbor blocks; and a calculation module for calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction.

[0019] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction method, which includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on the neighbor blocks in each angle direction, and determining the angle direction through deduplication as the valid angle direction; modifying the motion information of the unavailable neighbor blocks using the motion information of the reference block of the unavailable neighbor blocks; dividing the current block into multiple sub-blocks, and performing motion compensation using the motion information of the corresponding neighbor blocks of each sub-block in the valid angle direction to obtain the prediction value of each sub-block, the prediction values ​​of all sub-blocks constituting the prediction value of the current block, wherein the motion compensation of the sub-block in at least one valid angle direction uses the motion information of at least two corresponding neighbor blocks.

[0020] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, comprising: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for performing motion information deduplication on neighbor blocks in each angle direction, and the angle direction through deduplication is the valid angle direction; a modification module for modifying the motion information of unavailable neighbor blocks using the motion information of a reference block of the unavailable neighbor blocks; and a calculation module for performing motion compensation using the motion information of the corresponding neighbor blocks of each sub-block in the valid angle direction when the current block is divided into multiple sub-blocks, obtaining the prediction value of each sub-block, and the prediction values ​​of all sub-blocks constitute the prediction value of the current block, wherein the motion compensation of at least one sub-block in the valid angle direction uses the motion information of at least two of the corresponding neighbor blocks.

[0021] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle pattern inter-frame prediction method. This method includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on neighbor blocks in each angle direction, and determining the angle direction that passes the deduplication as the valid angle direction; filling the valid angle direction into the angle pattern list to obtain the angle pattern index of the valid angle direction; modifying the motion information of the unavailable neighbor blocks using the motion information of the reference block of the unavailable neighbor block; and calculating the prediction value of the current block using the motion information of available and / or unavailable neighbor blocks in each valid angle direction.

[0022] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle pattern inter-frame prediction device, which includes: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for performing motion information deduplication on neighbor blocks in each angle direction, and the angle direction that passes the deduplication is the valid angle direction; an input module for inputting the valid angle direction into the angle pattern list to obtain the angle pattern index of the valid angle direction; a modification module for modifying the motion information of the unavailable neighbor blocks using the motion information of the reference block of the unavailable neighbor blocks; and a calculation module for calculating the prediction value of the current block using the motion information of available and / or unavailable neighbor blocks in each valid angle direction.

[0023] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction method, which includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on neighbor blocks in each angle direction, and determining the angle direction that is deduplicated as the valid angle direction; determining the order of each valid angle direction using the texture direction of the current block; filling the valid angle directions into the mode list in sequence; modifying the motion information of unavailable neighbor blocks using the motion information of reference blocks of unavailable neighbor blocks; and calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction.

[0024] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle pattern inter-frame prediction device, the device comprising: a construction module for constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module for setting motion information for unavailable neighbor blocks; a deduplication module for performing motion information deduplication on neighbor blocks in each angle direction, and the angle direction with deduplication is the valid angle direction; a determination module for determining the order of each valid angle direction using the texture direction of the current block; a filling module for filling the valid angle directions into the pattern list in sequence; a modification module for modifying the motion information of unavailable neighbor blocks using the motion information of reference blocks of unavailable neighbor blocks; and a calculation module for calculating the prediction value of the current block using the motion information of available neighbor blocks and / or unavailable neighbor blocks in each valid angle direction.

[0025] To address the aforementioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction method, which includes: constructing a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; setting motion information for unavailable neighbor blocks; performing motion information deduplication on neighbor blocks in each angle direction, the angle direction of the deduplication being the valid angle direction; modifying the motion information of unavailable neighbor blocks using the motion information of reference blocks of unavailable neighbor blocks; dividing the current block into multiple sub-blocks, and using the motion information of each sub-block in the valid angle direction... The motion information of each sub-block is obtained by taking the motion information of the corresponding neighboring blocks. The motion information includes motion vectors. The first predicted value of each sub-block is corrected by multiple corrected motion vectors to obtain multiple second predicted values ​​of each sub-block. The first predicted value is obtained by motion compensation using the motion information. The corrected motion vector corresponding to the second predicted value with the smallest evaluation index is selected for each sub-block as the final corrected motion vector of the sub-block. The final corrected motion vectors of all sub-blocks are used for correction to obtain the corrected motion vector. The predicted value of each sub-block is obtained by using the motion information containing the corrected motion vector. The predicted values ​​of all sub-blocks constitute the predicted value of the current block.

[0026] To solve the above-mentioned technical problems, another technical solution adopted in this application is: providing an angle-mode inter-frame prediction device, the device comprising: a construction module, used to construct a candidate neighbor block list for the current block, the candidate neighbor block list including neighbor blocks of the current block in multiple angle directions, wherein the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks; a setting module, used to set motion information for unavailable neighbor blocks; a deduplication module, used to perform motion information deduplication on neighbor blocks in each angle direction, and the angle direction that passes the deduplication is the valid angle direction; a modification module, used to modify the motion information of unavailable neighbor blocks using the motion information of the reference block of the unavailable neighbor blocks; and a first calculation module, used to, when the current block is divided into multiple sub-blocks, respectively use the motion information of each sub-block in the valid angle direction. The motion information of each sub-block is obtained by analyzing the motion information of its neighboring blocks in the degree direction, including motion vectors. A first correction module is used to correct the first predicted value of each sub-block using multiple corrected motion vectors to obtain multiple second predicted values ​​for each sub-block. The first predicted value is obtained by motion compensation using the motion information. A selection module is used to select the corrected motion vector corresponding to the second predicted value with the smallest evaluation index for each sub-block as the final corrected motion vector of the sub-block. A second correction module is used to correct the motion using the final corrected motion vectors of all sub-blocks to obtain the corrected motion vector. A second calculation module is used to obtain the predicted value of each sub-block using the motion information containing the corrected motion vector. The predicted values ​​of all sub-blocks constitute the predicted value of the current block.

[0027] To solve the above-mentioned technical problems, another technical solution adopted in this application is: to provide an encoder, which includes a processor and a memory connected to the processor, wherein the memory stores program instructions; the processor is used to execute the program instructions stored in the memory to implement the above method.

[0028] To solve the above-mentioned technical problems, another technical solution adopted in this application is to provide a storage medium storing program instructions that, when executed, can implement the above-mentioned method.

[0029] By means of the above method, after obtaining the effective angle direction through deduplication, this application can only modify the motion information of unavailable neighbor blocks in the effective angle direction. Compared with the method of modifying the filling motion information of unavailable neighbor blocks in each angle direction, it can reduce the computational overhead. Attached Figure Description

[0030] Figure 1 This is a flowchart illustrating the first embodiment of the angle mode inter-frame prediction method of this application;

[0031] Figure 2 This is a diagram showing the neighboring blocks of the current block in five angular directions;

[0032] Figure 3 This is a flowchart illustrating the second embodiment of the angle mode inter-frame prediction method of this application;

[0033] Figure 4 This is a flowchart illustrating the third embodiment of the angle mode inter-frame prediction method of this application;

[0034] Figure 5 This is a flowchart illustrating the fourth embodiment of the angle mode inter-frame prediction method of this application;

[0035] Figure 6 This is a flowchart illustrating the fifth embodiment of the angle mode inter-frame prediction method of this application;

[0036] Figure 7 This is a flowchart illustrating the sixth embodiment of the angle mode inter-frame prediction method of this application;

[0037] Figure 8 yes Figure 7 A detailed flowchart of the S630 process;

[0038] Figure 9 This is a schematic diagram illustrating the process of selecting a first number of neighboring blocks for deduplication in the corresponding width and height directions in this application.

[0039] Figure 10 This is a schematic diagram illustrating the second number of neighboring blocks selected for deduplication in the corresponding width and height directions of this application;

[0040] Figure 11 This is a flowchart illustrating the seventh embodiment of the angle mode inter-frame prediction method of this application;

[0041] Figure 12 This is a diagram illustrating an additional plagiarism check under the first condition of this application;

[0042] Figure 13 This is another illustration illustrating the addition of a plagiarism check under the first condition of this application;

[0043] Figure 14 This is another illustration illustrating the addition of a plagiarism check under the first condition of this application;

[0044] Figure 15 This is another illustration illustrating the additional plagiarism check under the first condition of this application;

[0045] Figure 16 This is a flowchart illustrating the eighth embodiment of the angle mode inter-frame prediction method of this application;

[0046] Figure 17 This is a schematic diagram illustrating the reduction of one plagiarism check under the second condition of this application;

[0047] Figure 18This is another illustration illustrating the reduction of one plagiarism check under the second condition of this application;

[0048] Figure 19 This is another illustration of reducing one plagiarism check under the second condition of this application;

[0049] Figure 20 This is a flowchart illustrating the ninth embodiment of the angle mode inter-frame prediction method of this application;

[0050] Figure 21 This is a flowchart illustrating the tenth embodiment of the angle mode inter-frame prediction method of this application;

[0051] Figure 22 This is a schematic diagram illustrating the calculation of the motion vector of the first sub-block using two adjacent blocks in the horizontal and vertical directions, respectively, according to this application.

[0052] Figure 23 This is a flowchart illustrating the eleventh embodiment of the angle mode inter-frame prediction method of this application;

[0053] Figure 24 This is a flowchart illustrating the twelfth embodiment of the angle mode inter-frame prediction method of this application;

[0054] Figure 25 yes Figure 24 A detailed flowchart of the S1240 process;

[0055] Figure 26 This is a flowchart illustrating the thirteenth embodiment of the angle mode inter-frame prediction method of this application;

[0056] Figure 27 yes Figure 26 A detailed flowchart of the S1306 process;

[0057] Figure 28 This is a schematic diagram illustrating the search for the forward correction motion vector within the search range of the forward first prediction block in this application;

[0058] Figure 29 This is a schematic diagram of the structure of a first embodiment of an angle mode inter-frame prediction device according to this application;

[0059] Figure 30 This is a schematic diagram of the structure of a second embodiment of an angle mode inter-frame prediction device according to this application;

[0060] Figure 31 This is a schematic diagram of the structure of a third embodiment of an angle mode inter-frame prediction device according to this application;

[0061] Figure 32 This is a schematic diagram of the structure of a fourth embodiment of an angle mode inter-frame prediction device according to this application;

[0062] Figure 33This is a schematic diagram of the structure of a fifth embodiment of an angle mode inter-frame prediction device according to this application;

[0063] Figure 34 This is a schematic diagram of the structure of a sixth embodiment of an angle mode inter-frame prediction device according to this application;

[0064] Figure 35 This is a schematic diagram of the structure of the seventh embodiment of an angle mode inter-frame prediction device according to this application;

[0065] Figure 36 This is a schematic diagram of the structure of the eighth embodiment of an angle mode inter-frame prediction device according to this application;

[0066] Figure 37 This is a schematic diagram of the structure of the ninth embodiment of an angle mode inter-frame prediction device according to this application;

[0067] Figure 38 This is a schematic diagram of the structure of the tenth embodiment of an angle mode inter-frame prediction device according to this application;

[0068] Figure 39 This is a schematic diagram of the structure of an embodiment of the encoder of this application;

[0069] Figure 40 This is a schematic diagram of the structure of an embodiment of the storage medium of this application;

[0070] Figure 41 This is a schematic diagram of the structure of an embodiment of the electronic device of this application. Detailed Implementation

[0071] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of the embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.

[0072] The terms "first," "second," and "third" used in this application are for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined as "first," "second," or "third" may explicitly or implicitly include at least one of that feature. In the description of this application, "multiple" means at least two, such as two, three, etc., unless otherwise explicitly specified.

[0073] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments without conflict.

[0074] Figure 1 This is a flowchart illustrating the first embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily use it in the same way. Figure 1 The illustrated process sequence is limited. For example... Figure 1 As shown, this embodiment may include:

[0075] S110: Build a list of candidate neighboring blocks for the current block.

[0076] The current block can also be called the current coding block, which is the block that is currently being encoded. In some cases, the coding block can be called a coding unit (CU). The video frame in which the current block is located can be called the current frame.

[0077] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions. Both the current block and neighbor blocks belong to the current frame. Neighbor blocks are located on the encoded side of the current block; for example, when the encoding direction is from left to right and top to bottom, neighbor blocks are located to the left and top of the current block. Referring to the concept of angular patterns in intra-frame prediction, neighbor blocks can be determined by projecting the current block onto the encoded side in each angular direction. Neighbor blocks in different angular directions may overlap. All neighbor blocks can be the same size and smaller than the size of the current block.

[0078] Depending on the current block's position, neighboring blocks may be actual blocks within the current frame or blocks that do not exist beyond the current frame boundary. For actual neighboring blocks, they may be encoded or uncoded. The prediction mode used for encoded neighboring blocks can be inter-frame prediction, intra-frame prediction, or Intra Block Copy (IBC), etc. In this application, encoded inter-frame predicted neighboring blocks can be called usable neighboring blocks, and remaining neighboring blocks (e.g., non-existent blocks, uncoded blocks, intra-frame blocks, etc.) can be called unusable neighboring blocks.

[0079] Optionally, the multiple angular directions include at least two of the following: horizontal, vertical, horizontal upward, horizontal downward, and vertical to the right. (The following is a combination of...) Figure 2 This section explains the situation involving five directions (horizontal, vertical, horizontal upward, horizontal downward, and vertical to the right):

[0080] Figure 2This diagram shows the neighboring blocks of the current block in five angular directions. A1 to A2 are defined based on the relative positions of the neighboring blocks to the current block. N Blocks that are adjacent to the current block in the horizontal direction can be called horizontal neighboring blocks; B1~B N A is a neighboring block in the vertical direction of the current block, and can be called a vertical neighboring block; E is a neighboring block in the horizontal upward direction of the current block, and can be called a horizontal upward neighboring block; C1~C N The blocks that are horizontally downwards from the current block can be called horizontally downward neighboring blocks; D1~D N A neighboring block perpendicular to the right of the current block can be referred to as a perpendicular right neighboring block. Based on the projection results of the current block in each angular direction, the neighboring blocks of the current block in the horizontal angular direction 0 include at least some horizontal neighbors; the neighboring blocks in the vertical direction 1 include at least some vertical neighbors; the neighboring blocks in the horizontal upward direction 2 include horizontal upward neighbors, at least some horizontal neighbors, and at least some vertical neighbors; the neighboring blocks in the horizontal downward direction 3 include at least some horizontal neighbors and at least some horizontal downward neighbors; and the neighboring blocks in the vertical right direction 4 include at least some vertical neighbors and at least some perpendicular right neighbors. In this case, the candidate neighboring block list constructed for the current block can be {C1~C4}. N A1~A N E, B1~B N D1~D N In the candidate neighbor block list of the current block, in addition to recording the number / identifier of each neighbor block, motion information of the neighbor blocks is also recorded. This motion information may include motion vectors and reference frame index information (forward reference frame index information and / or backward reference frame index information).

[0081] S120: Set motion information for unavailable neighboring blocks.

[0082] Since available neighboring blocks have motion information while unavailable neighboring blocks do not, motion information needs to be set for unavailable neighboring blocks.

[0083] In one specific implementation, the initial value (motion vector is 0, forward / backward reference frame index is -1) can be directly set to the motion information of unavailable neighboring blocks. If the reference frame index of a neighboring block is -1, it means that the reference frame of that neighboring block does not exist.

[0084] In another specific implementation, motion information can be set for the unavailable neighboring block based on the motion information of the temporal co-occurring block of the currently unavailable neighboring block. For details of the implementation process, please refer to the following embodiments. Here, the temporal co-occurring block is the co-occurring block of the currently unavailable neighboring block in a reference frame of the reference frame list of the current frame, for example, the co-occurring block in the first reference frame (reference frame index 0).

[0085] S130: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0086] For specific methods of plagiarism detection, please refer to the examples below.

[0087] S140: Modify the motion information of unavailable neighboring blocks in the effective angle direction using the motion information of the reference block of the unavailable neighboring block in the effective angle direction.

[0088] The reference block can be the previous neighbor of an unavailable neighbor, the next neighbor of an unavailable neighbor, or a temporal co-occurrence block of an unavailable neighbor, etc.

[0089] S150: Calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0090] The current block can be divided into multiple sub-blocks. Referring to the concept of intra-frame prediction, for each valid angular direction, the motion information of each sub-block can be determined based on the motion information of its corresponding neighboring blocks in that direction. Then, motion compensation is performed on the sub-block using this motion information to obtain its predicted value. The predicted values ​​of all sub-blocks constitute the predicted value of the current block. After obtaining the predicted value of the current block, the rate-distortion cost can be calculated based on the predicted value and the original value of the current block. Performing the above process for each valid angular direction yields the predicted values ​​and rate-distortion costs for all valid angular directions.

[0091] The corresponding neighboring block of a sub-block in an effective angular direction refers to the neighboring block determined by projecting the sub-block onto the encoded side of the current block according to the effective angular direction.

[0092] If the current valid angular direction contains both available and unavailable neighboring blocks, then the motion information of the neighboring blocks includes the motion information of both available and unavailable neighboring blocks; if the current valid angular direction contains only available neighboring blocks, then the motion information of the neighboring blocks includes the motion information of the available neighboring blocks; if the current valid angular direction contains only unavailable neighboring blocks, then the motion information of the neighboring blocks includes the motion information of the unavailable neighboring blocks.

[0093] In this embodiment, after obtaining the effective angle direction through deduplication, only the motion information of unusable neighboring blocks in the effective angle direction is modified. Compared with modifying the motion information of unusable neighboring blocks in every angle direction, this reduces computational overhead.

[0094] Figure 3 This is a flowchart illustrating the second embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with the desired result. Figure 3The illustrated process sequence is limited. This embodiment is a further extension of the above-described S140. Figure 3 As shown, this embodiment may include:

[0095] S210: Sort neighboring blocks in the effective angle direction according to the modification order.

[0096] Neighboring blocks in different angle directions may be duplicated. During sorting, they are not sorted independently according to each valid angle direction. Instead, after collecting all neighboring blocks in all valid angle directions and removing duplicates, they are sorted according to their relative position to the current block. The sorting order can be clockwise, counterclockwise, etc.

[0097] It should be noted that the sorting order of neighboring blocks in the effective angular direction is the same as the sorting order of neighboring blocks in the candidate neighboring block list.

[0098] S220: Determine whether the first neighboring block after sorting is an unusable neighboring block.

[0099] The first neighboring block after sorting the neighboring blocks in the effective angular direction may not be the same as the first neighboring block in the candidate list.

[0100] If so, then execute S230.

[0101] S230: Modify the motion information of the first neighboring block using the motion information of the previous and / or next neighboring blocks in the candidate neighboring block list after sorting.

[0102] In one specific implementation, if the preceding neighbor of the first neighbor is a usable neighbor, then the motion information of the first neighbor is modified using the motion information of the preceding neighbor; otherwise, the motion information of the first neighbor is set to an initial value.

[0103] In another specific implementation, if the next neighbor of the first neighbor is a usable neighbor, then the motion information of the first neighbor is modified using the motion information of the next neighbor; otherwise, the motion information of the first neighbor is set to the initial value.

[0104] In another specific implementation, if the preceding neighbor of the first neighbor is a usable neighbor, then the motion information of the first neighbor is modified using the motion information of the preceding neighbor; otherwise, it is determined whether the following neighbor is a usable neighbor. If so, the motion information of the first neighbor is modified using the motion information of the following neighbor; otherwise, the motion information of the first neighbor is set to its initial value.

[0105] In another specific implementation, if both the preceding and following neighboring blocks of the first neighboring block are available neighboring blocks, the motion information of the first neighboring block is modified using the weighted average of the motion information of the preceding and following neighboring blocks; if one of the preceding and following neighboring blocks of the first neighboring block is available neighboring block, the motion information of the first neighboring block is modified using the motion information of the available neighboring block; if both the preceding and following neighboring blocks of the first neighboring block are unavailable neighboring blocks, the motion information of the first neighboring block is set to an initial value.

[0106] In this embodiment, different motion information modification strategies are applied to the first neighboring block based on whether it is an unusable neighboring block after sorting the neighboring blocks in the effective angular direction, which can improve the accuracy of encoding.

[0107] Figure 4 This is a flowchart illustrating the third embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with a different result. Figure 4 The illustrated process sequence is limited. This embodiment is a further extension of the above-described S140. Figure 4 As shown, this embodiment may include:

[0108] S310: Sort neighboring blocks in the effective angle direction according to the modification order.

[0109] S320: Determine whether the first neighboring block after sorting is an unusable neighboring block.

[0110] If so, then execute S330.

[0111] S330: Determine whether the temporal co-occurrence block of the first neighboring block is available.

[0112] Optionally, the frame containing the temporal co-occurrence block of the first neighboring block is a reference frame in the reference frame list of the current block, and the position and size of the temporal co-occurrence block in the reference frame are exactly the same as the position and size of the first neighboring block in the current frame.

[0113] Whether a temporal co-occurrence block is usable can be understood as whether the temporal co-occurrence block has motion information, or as whether the temporal co-occurrence block uses inter-frame predictive coding.

[0114] If so, then execute S340.

[0115] S340: Modify the motion information of the first neighboring block using the motion information of the temporal co-location block of the first neighboring block.

[0116] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0117] In this embodiment, different motion information modification strategies are applied to the first neighboring block based on whether it is an unusable neighboring block after sorting the neighboring blocks in the effective angular direction, which can improve the accuracy of encoding.

[0118] Figure 5 This is a flowchart illustrating the fourth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with the desired result. Figure 5 The illustrated process sequence is limited. This embodiment is a further extension of the above-described S120, such as... Figure 5 As shown, this embodiment may include:

[0119] S410: Determine whether the temporal co-occurrence block of an unavailable neighboring block is available.

[0120] If yes, then execute S420; otherwise, execute S430.

[0121] S420: Use the motion information of the temporal co-location block to set motion information for unavailable neighboring blocks.

[0122] In one specific implementation, the motion information of the temporal co-location block can be used as the motion information of the unavailable neighboring block.

[0123] In another specific implementation, the forward motion information of the unavailable neighbor block can be set as the forward motion information or backward motion information of the forward co-block, and the backward motion information of the unavailable neighbor block can be set as the backward motion information or forward motion information of the backward co-block. The frame where the forward co-block is located is a reference frame in the forward reference frame list of the current block, and the frame where the backward co-block is located is a reference frame in the backward reference frame list of the current block.

[0124] When a forward reference frame for a forward co-block exists, the forward motion information of an unavailable neighboring block can be set as the forward motion information of the forward co-block; or, when a backward reference frame for a forward co-block exists, the forward motion information of an unavailable neighboring block can be set as the backward motion information of the forward co-block.

[0125] When a backward reference frame for a backward co-op block exists, the backward motion information of an unavailable neighbor block can be set as the backward motion information of the backward co-op block; or, when a forward reference frame for a backward co-op block exists, the backward motion information of an unavailable neighbor block can be set as the forward motion information of the backward co-op block.

[0126] In another specific implementation, the forward motion information or backward motion information of the temporal co-location block can be scaled according to the difference in image order index and then used as the forward motion information and backward motion information of the unavailable neighboring block.

[0127] It is understandable that each frame of an image has a corresponding Picture Order Count (POC), which represents the order in which the images are played. The formula for scaling based on the difference in picture order indices can be as follows:

[0128] scale_MV = MV / t0*t1,

[0129] t1 = POC0 - POC1,

[0130] t0 = POC2 - POC3,

[0131] Where scale_MV represents the forward / backward motion information of currently unavailable neighboring blocks, and MV represents the forward / backward motion information of temporal co-located blocks.

[0132] When the current frame is a B-frame (bidirectional difference frame), it is necessary to calculate the forward motion information and backward motion information of the currently unavailable neighboring blocks.

[0133] If scale_MV is the forward motion information of the currently unavailable neighboring block, then t1 is the difference (distance) between POC1 of the current frame and POC0 of the forward reference frame of the current frame, and t0 is the difference between POC2 of the frame where the temporal co-block is located and POC3 of the forward / backward reference frame of the temporal co-block.

[0134] If scale_MV is the backward motion information of the currently unavailable neighboring block, then t1 is the difference between POC1 of the current frame and POC0 of the backward reference frame of the current frame, and t0 is the difference between POC2 of the frame where the temporal co-block is located and POC3 of the forward / backward reference frame of the temporal co-block.

[0135] When the current frame is a P-frame (one-way difference frame), only the forward motion information of the currently unavailable neighboring blocks needs to be calculated. t1 is the difference between POC1 of the current frame and POC0 of the reference frame of the current frame, and t0 is the difference between POC2 of the frame containing the temporal co-block and POC3 of the forward / backward reference frame of the temporal co-block.

[0136] S430: Set the initial value to the motion information of unavailable neighboring blocks.

[0137] As mentioned earlier, the initial value of the motion vector can be set to 0, and the motion information of the reference frame index can be set to -1.

[0138] Through the implementation of this embodiment, motion information for unavailable neighboring blocks can be set based on the available temporal co-occurrence block. Only when the temporal co-occurrence block of an unavailable neighboring block is unavailable should the motion information of the unavailable neighboring block be set to an initial value. Compared to directly setting the motion information of unavailable neighboring blocks to an initial value, this reduces the error caused by setting motion information for unavailable neighboring blocks and improves the accuracy of encoding.

[0139] Figure 6 This is a flowchart illustrating the fifth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with the correct one. Figure 6 The illustrated process sequence is limited. For example... Figure 6 As shown, this embodiment may include:

[0140] S510: Build a list of candidate neighboring blocks for the current block.

[0141] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0142] S520: Determine whether the temporal co-occurrence block of an unavailable neighboring block is available.

[0143] The frame containing the temporal co-location block is the first reference frame in the reference frame list of the current block.

[0144] If yes, then execute S530; otherwise, execute S540.

[0145] S530: Use the motion information of the temporal co-location block to set motion information for unavailable neighboring blocks.

[0146] In one specific implementation, the motion information of the temporal co-location block can be used as the motion information of the unavailable neighboring block.

[0147] In another specific implementation, the forward motion information of the unavailable neighbor block can be set as the forward motion information or backward motion information of the forward co-block, and the backward motion information of the unavailable neighbor block can be set as the backward motion information or forward motion information of the backward co-block. The frame where the forward co-block is located is a reference frame in the forward reference frame list of the current block, and the frame where the backward co-block is located is a reference frame in the backward reference frame list of the current block.

[0148] In another specific implementation, the forward motion information or backward motion information of the temporal co-location block is scaled according to the difference in image order index and then used as the forward motion information and backward motion information of the unavailable neighboring block.

[0149] After executing S530, the process jumps to S550.

[0150] S540: Set the initial value to the motion information of unavailable neighboring blocks.

[0151] After executing S540, the process jumps to S550.

[0152] S550: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0153] S560: Modify the motion information of the available neighboring blocks whose motion information is the initial value by using the motion information of the reference block of the unavailable neighboring block whose motion information is the initial value.

[0154] For specific modifications, please refer to other embodiments in this application.

[0155] S570: Calculate the predicted value of the current block using the motion information of available and unavailable neighboring blocks in each effective angular direction.

[0156] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0157] In this embodiment, when it is determined that the temporal co-occurrence block of an unavailable neighbor is available, the motion information of the unavailable neighbor is configured using the motion information of the temporal co-occurrence block. Only when it is determined that the temporal co-occurrence block of an unavailable neighbor is unavailable, the motion information of the unavailable neighbor is set to an initial value. Compared with the method of directly setting the motion information of the unavailable neighbor to an initial value, the error caused by configuring motion information for the unavailable neighbor can be reduced. Furthermore, after performing motion information deduplication on the neighbor blocks in each angular direction to obtain the effective angular direction, only the motion information of the unavailable neighbor whose motion information is set to an initial value is modified. Compared with the method of directly modifying the motion information of each unavailable neighbor, the computational overhead required to modify the motion information of the unavailable neighbor can be reduced.

[0158] Figure 7 This is a flowchart illustrating the sixth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with the correct one. Figure 7 The illustrated process sequence is limited. For example... Figure 7 As shown, this embodiment may include:

[0159] S610: Build a list of candidate neighboring blocks for the current block.

[0160] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0161] S620: Set motion information for unavailable neighboring blocks.

[0162] S630: Select at least one pair of neighboring blocks in each angular direction based on the size of the current block to perform motion information deduplication. The angular direction that is deduplicated is the valid angular direction.

[0163] Optionally, the selected neighboring blocks in the same angular direction are arranged at equal intervals. Of course, in other embodiments, neighboring blocks in the same angular direction can also be selected according to other methods (such as random selection).

[0164] Generally, the accuracy of the effective angle direction obtained from plagiarism detection depends on factors such as the number of plagiarism checks and the size of the current block. Specifically, when the sizes are consistent, the more plagiarism checks are performed on each angle direction of the current block, the more accurate the effective angle direction obtained from the plagiarism check results. When the number of plagiarism checks is consistent, the effective angle direction obtained for a smaller current block is more accurate than for a larger current block.

[0165] Therefore, for the current block that is too large, the number of neighboring block pairs selected in each angular direction can be increased, i.e., the number of deduplication checks can be increased. (See also...) Figure 8 The specific implementation process may include:

[0166] S631: Determine whether the width / height of the current block is greater than the first threshold.

[0167] A current block whose width / height is greater than a first threshold can be considered a block with a larger size; a current block whose width / height is both less than or equal to the first threshold can be considered a block with a smaller size. For example, the first threshold can be set to 32.

[0168] If yes, then execute S632; otherwise, execute S633.

[0169] S632: Select the first number of neighboring blocks in the direction corresponding to the width / height for deduplication.

[0170] If the width is greater than the first threshold, then a first number of neighboring blocks are selected in the direction corresponding to the width for deduplication; if the height is greater than the first threshold, then a first number of neighboring blocks are selected in the direction corresponding to the height for deduplication. The direction corresponding to the width includes vertical and / or vertically to the right, and the direction corresponding to the height includes horizontal and / or horizontally downwards.

[0171] Combination Figure 9 An example is given for the case where both the width and height are greater than the first threshold (32) (the current block size is 64×64).

[0172] like Figure 9 As shown, four equally spaced neighboring blocks are selected in each of the directions corresponding to the width (vertical and vertically to the right) for deduplication. Among them, neighboring blocks B1 to B2 in the vertical direction... 2N Select B1, B K B 2K and B3K N = 64, K = N / 4, the adjacent blocks D1 to D2 in the vertical right direction N Select D1, D K D 2K and D 3K Therefore, the neighboring block pairs that need to be checked for duplicates in the corresponding width direction include (B1, B... K (B) K B 2K (B) 2K B 3K (B) 3K ,D1)(D1,D K ) and (D K D 2K ).

[0173] Four equally spaced neighboring blocks are selected in each of the corresponding directions (horizontal and downward) for deduplication. Specifically, neighboring blocks A1 to A2 in the horizontal direction are selected for deduplication. N Select A1, A K A 2K and A 3K In the horizontal downward direction, the adjacent blocks C1 to C N Select C1, C K C 2K and C 3K Therefore, the neighboring block pairs that need to be checked in the corresponding high direction include (A1, A... K ), (A K A 2K ), (A 2K A 3K ), (A 3K ,C1), (C1,C K ), (C K C 2K ) and (C 2K C 3K ).

[0174] In addition, the neighboring block pairs that need to be checked in the horizontal upward direction include (A1,E) and (E,B1).

[0175] S633: Select a second number of neighboring blocks in the direction corresponding to the width / height for deduplication.

[0176] The first quantity is greater than the second quantity, and the second quantity is greater than 1.

[0177] Combination Figure 10 An example is given for the case where both width and height are equal to the first threshold (32) (the current block size is 32×32).

[0178] like Figure 10As shown, two equally spaced neighboring blocks are selected in each of the directions corresponding to the width (vertical and vertically to the right) for deduplication. Specifically, neighboring blocks B1 to B2 in the vertical direction are selected for deduplication. N Select B1 and B K N = 32, K = N / 2, the adjacent blocks D1 to D2 in the vertical right direction N Select D1 and D K Therefore, the neighboring block pairs that need to be checked for duplicates in the corresponding width direction include (B1, B... K (B) K (D1) and (D1,D K ).

[0179] Two neighboring blocks are selected in each of the corresponding directions (horizontal and downward) for deduplication. Among them, neighboring blocks A1 to A2 in the horizontal direction are selected for deduplication. N Select A1 and A K In the horizontal downward direction, the adjacent blocks C1 to C N Select C1 and C K Therefore, the neighboring block pairs that need to be checked in the corresponding high direction include (A1, A... K ), (A K (C1) and (C1,C) K ).

[0180] In addition, the neighboring block pairs that need to be checked in the horizontal upward direction include (A1,E) and (E,B1).

[0181] S640: Modify the motion information of the available neighboring blocks using the motion information of the reference blocks of the unavailable neighboring blocks.

[0182] The modification can be applied to the motion information of unavailable neighboring blocks in the valid directions only, or it can be applied to the motion information of unavailable neighboring blocks in all directions.

[0183] S650: Calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0184] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0185] In this embodiment, the number of neighboring blocks selected for deduplication in each angular direction is determined based on the size of the current block. Compared to the method of selecting the same number of neighboring blocks for deduplication in each angular direction for current blocks of all sizes, this makes the final selected effective angular direction more accurate.

[0186] Figure 11 This is a flowchart illustrating the seventh embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with a different result. Figure 11 The illustrated process sequence is limited. For example... Figure 11 As shown, this embodiment may include:

[0187] S710: Build a list of candidate neighboring blocks for the current block.

[0188] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0189] S720: Set motion information for unavailable neighboring blocks.

[0190] S730: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0191] If the angle and direction meet the first condition, then at least one additional deduplication check will be performed.

[0192] In one specific implementation, the first condition may be that the plagiarism check fails in the horizontal and / or vertical directions. If the plagiarism check fails in the horizontal and / or vertical directions, at least one more plagiarism check is performed.

[0193] Taking adding a deduplication check as an example, the neighboring blocks include N horizontal neighboring blocks located in the horizontal direction of the current block and N vertical neighboring blocks located in the vertical direction of the current block. The deduplication check added in the horizontal direction is the deduplication check between the Kth and Nth horizontal neighboring blocks sorted from top to bottom, and the deduplication check added in the vertical direction is the deduplication check between the Kth and Nth vertical neighboring blocks sorted from left to right. K = N / i, where i is the number of horizontal or vertical neighboring blocks selected in the deduplication checks that have been completed.

[0194] In one specific implementation, i can be 2.

[0195] Combination Figure 12 Examples of cases where plagiarism checks failed in both the horizontal and vertical directions are provided. Figure 12 As shown, the horizontal adjacent block pairs (A1, A2, A3, A4) K If the plagiarism check fails, an additional check of adjacent block pairs (A) will be performed horizontally. K A N Deduplication check; vertical adjacent block pairs (B1, B...) K The plagiarism check failed, which adds an extra check to the adjacent block pair (B) in the vertical direction. K B N (This is a plagiarism check.)

[0196] If a plagiarism check fails in the horizontal and / or vertical directions, at least one additional plagiarism check is performed. This allows for the selection of effective angle directions based on multiple plagiarism check results, thereby improving plagiarism check accuracy and ultimately enhancing the accuracy of the final selected effective angle direction.

[0197] In another specific implementation, the first condition can be that the angle direction is horizontal downwards or vertical to the right. If the angle direction is horizontal downwards or vertical to the right, then at least one additional deduplication check is performed.

[0198] Since neighboring blocks in the horizontal downward and vertical right directions are not completely checked during the plagiarism check process, at least one additional check can be performed in the horizontal downward and vertical right directions to improve the accuracy of the plagiarism check.

[0199] Optionally, the neighboring blocks include N horizontal neighboring blocks located in the horizontal direction of the current block and N vertical neighboring blocks located in the vertical direction of the current block. The deduplication check increases in the horizontal downward direction for the deduplication check between two horizontal neighboring blocks, and the deduplication check increases in the vertical right direction for the deduplication check between two vertical neighboring blocks.

[0200] Taking adding one more deduplication check as an example, the deduplication check added in the horizontal downward direction is the check between the 3rd and Kth horizontal neighboring blocks sorted from top to bottom, and the deduplication check added in the vertical right direction is the check between the 3rd and Kth vertical neighboring blocks sorted from left to right, where K = N / i, and i is the number of horizontal / vertical neighboring blocks selected in the horizontal / vertical deduplication check.

[0201] Combination Figure 13 For example, Figure 13 As shown, add a pair of neighboring blocks (A3, A) in the horizontal downward direction. K For deduplication, add pairs of adjacent blocks (B3, B) vertically to the right. K (This is a plagiarism check.)

[0202] In another specific implementation, the first condition can be that the plagiarism check results for the angle direction that failed the plagiarism check include the absence of reference frames for a pair of neighboring blocks. If the plagiarism check results for the angle direction that failed the plagiarism check include the absence of reference frames for a pair of neighboring blocks, then at least one more plagiarism check is added for the angle direction that failed the plagiarism check.

[0203] Specifically, the sequence numbers of at least one pair of neighboring blocks that do not exist in the reference frame can be shifted. Each pair of shifted neighboring blocks still belongs to the angle direction that has not passed the deduplication check, and the sequence numbers are different from those of the pair of neighboring blocks that do not exist in the reference frame. Motion information deduplication is performed on at least one pair of shifted neighboring blocks.

[0204] Combination Figure 14 For example, Figure 14 As shown, the neighboring block pair (A1, A K If the reference frames for two neighboring blocks in a given block do not exist, shift the sequence numbers of the two neighboring blocks in the same direction by one position to obtain the neighboring block pair (A2, A...). K+1 Then for (A2,A) K+1 Perform a plagiarism check on the sports information.

[0205] And / or, you can select a pair of neighboring blocks that do not exist in the reference frame and their adjacent blocks in a direction away from the current block for motion information deduplication.

[0206] Combination Figure 15 For example, Figure 15 As shown, the neighboring block pair (A1, A K If the reference frames for two neighboring blocks in a given block do not exist, then the neighboring block pair (a1, a2) consisting of adjacent blocks in the direction away from the current block is selected. K Perform a plagiarism check on the sports information.

[0207] S740: Modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of unavailable neighboring blocks.

[0208] S750: Calculate the predicted value of the current block using the motion information of the available and / or unavailable neighboring blocks in each of the effective angular directions.

[0209] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0210] In this embodiment, when performing motion information deduplication on neighboring blocks, if the angle and direction meet the first condition, adding at least one deduplication check can make the deduplication results more accurate, and thus the obtained effective angle and direction are more accurate.

[0211] Figure 16 This is a flowchart illustrating the eighth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with the original. Figure 16 The illustrated process sequence is limited. For example... Figure 16 As shown, this embodiment may include:

[0212] S810: Build a list of candidate neighboring blocks for the current block.

[0213] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0214] S820: Set motion information for unavailable neighboring blocks.

[0215] S830: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0216] If at least two of the horizontal, vertical, and upward horizontal plagiarism check results meet the second condition, then at least one horizontal plagiarism check will be reduced.

[0217] Optionally, the horizontal deduplication includes a first deduplication and a second deduplication. The first deduplication is to check the motion information between the horizontally upward neighboring block and the first horizontal neighboring block. The second deduplication is to check the motion information between the horizontally upward neighboring block and the first vertical neighboring block. The horizontally upward neighboring block is located in the horizontal direction of the current block. The first horizontal neighboring block is located in the horizontal direction of the current block and is adjacent to the horizontally upward neighboring block. The first vertical neighboring block is located in the vertical direction of the current block and is adjacent to the horizontally upward neighboring block.

[0218] If at least two of the horizontal, vertical, and upward horizontal plagiarism check results meet the second condition, then at least one horizontal plagiarism check will be reduced, including:

[0219] In one specific implementation, the second condition can be: both horizontal and vertical are valid angular directions.

[0220] If both the horizontal and vertical directions are valid angular directions, then there is no need to check for duplicates in the horizontal direction to determine that the horizontal direction is a valid angular direction.

[0221] Combination Figure 17 For example, Figure 17 As shown, (A1,A) K (B1, B) represents the horizontal neighbor pairs identified through motion information. K If the adjacent block pairs in the vertical direction are checked for duplicates through motion information, that is, both the horizontal and vertical directions are valid angle directions, then there is no need to check the motion information of the adjacent block pairs (A1,E) and (E,B1) in the horizontal direction.

[0222] In another specific implementation, the second condition can be: the horizontal direction is an effective angle and one of the first and second plagiarism checks is valid.

[0223] If the horizontal direction is a valid angle and one of the first and second plagiarism checks is valid, then it is unnecessary to perform the other of the first and second plagiarism checks, and the horizontal direction is determined to be a valid angle.

[0224] Combination Figure 18 For example, Figure 18 As shown, the horizontal adjacent block pairs (A1, A2, A3, A4) K If the horizontal direction is valid and the neighboring block pair (E, B1) in the horizontal upward direction is also valid after the second deduplication check, then there is no need to perform a motion information deduplication check on the neighboring block pair (A1, E) in the horizontal upward direction, i.e., no need to perform the first deduplication check, and the horizontal upward direction can be determined as a valid angle direction.

[0225] In another specific implementation, the second condition can be: vertical is an effective angular direction and one of the first and second plagiarism checks is valid.

[0226] If vertical is the valid angular direction and one of the first and second plagiarism checks is valid, then it is unnecessary to perform the other of the first and second plagiarism checks, and the horizontal direction is determined to be the valid angular direction.

[0227] Combination Figure 19 For example, Figure 19 As shown, the vertical adjacent block pairs (B1, B...) K If the motion information is checked for duplicates, meaning the vertical direction is valid, and the adjacent block pair (A1,E) in the horizontal upward direction is checked for duplicates, meaning the first check result is valid, then there is no need to check the motion information of the adjacent block pair (E,B1) in the horizontal upward direction, i.e., there is no need to perform a second check, and the horizontal upward direction can be determined as a valid angle direction.

[0228] S840: Modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of unavailable neighboring blocks.

[0229] S850: Calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0230] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0231] In this embodiment, when performing duplicate checks on neighboring blocks, if at least two of the duplicate check results for horizontal, vertical, and horizontally upward directions satisfy the second condition, then at least one duplicate check for the horizontal direction is reduced. Compared to performing duplicate checks twice for each horizontal direction, this reduces the computational overhead required during the duplicate check process.

[0232] Figure 20 This is a flowchart illustrating the ninth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with a different result. Figure 20 The illustrated process sequence is limited. For example... Figure 20 As shown, this embodiment may include:

[0233] S910: Build a list of candidate neighboring blocks for the current block.

[0234] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0235] S920: Set motion information for unavailable neighboring blocks.

[0236] S930: Perform motion information deduplication on neighboring blocks in each angular direction. The angular direction of the deduplication is the valid angular direction. The deduplication includes determining whether the image sequence index of the reference frames of at least one pair of selected neighboring blocks is the same and whether the motion vectors are the same.

[0237] An angle direction is considered invalid only if the image sequence index and motion vector of the reference frames of neighboring blocks in an angular direction are the same.

[0238] In addition, deduplication can also include determining whether the reference frame indices of at least one pair of selected adjacent blocks are the same. Specifically, when deduplication includes determining whether the reference frame index, motion vector, and image sequence index of the reference frame are the same, the order in which these three are determined is not limited.

[0239] The following example illustrates the process of deduplication for two neighboring blocks, Nei_b1 and Nei_b2, at a given angle, by first determining the reference frame index and motion vector, and then checking if the image sequence indices of the reference frames are the same:

[0240] (i) Determine whether the forward reference frame and the backward reference frame of Nei_b1 exist (whether the reference frame index is greater than or equal to 0). If one of them exists, proceed to (ii); otherwise, determine that this angle direction is invalid.

[0241] (ii) Determine if the forward reference frame and the backward reference frame of Nei_b2 exist. If one of them exists, proceed to (iii); otherwise, determine that this angle direction is invalid.

[0242] (iii) Determine whether the forward reference frame indices of Nei_b1 and Nei_b2 are the same. If they are the same, proceed to (iv); otherwise, determine that this angle direction is invalid.

[0243] (iv) Determine if the forward reference frame of Nei_b1 exists and if the forward reference motion vectors of Nei_b1 and Nei_b2 are the same. If they exist and are not the same, then the angle direction is considered valid; otherwise, proceed to (v).

[0244] (v) Determine if the backward reference frame indices of Nei_b1 and Nei_b2 are the same. If they are the same, proceed to (vi). Otherwise, determine that the angle direction is valid.

[0245] (vi) Determine if the backward reference frame of Nei_b1 exists and if the backward reference motion vectors of Nei_b1 and Nei_b2 are the same. If they exist and are not the same, then the angle direction is determined to be valid; otherwise, proceed to (vii).

[0246] (vii) Determine whether the image sequence indices of the reference frames of Nei_b1 and Nei_b2 are the same. If they are the same, determine that this angle direction is invalid; otherwise, determine that this angle direction is valid.

[0247] For reference frames with the same image sequence index, their reference frame indices in the forward and / or backward reference frame index lists of different neighboring blocks may differ. Therefore, if only the reference frame index and motion vector are used for judgment, it's possible that two neighboring blocks might have different reference frame indices in their motion information, causing the corresponding angle direction to be deemed valid, even though their reference frame image sequence indices and motion vectors are the same. In essence, the motion information of these two neighboring blocks is identical, and the corresponding angle direction should be invalid. Therefore, adding a check for identical image sequence indices of reference frames during the deduplication process can improve the accuracy of the judgment results.

[0248] S940: Modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of unavailable neighboring blocks.

[0249] S950: Calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0250] For further detailed descriptions of the steps in this embodiment, please refer to other embodiments in this application, which will not be repeated here.

[0251] In this embodiment, the motion information deduplication process for neighboring blocks includes determining whether the image sequence indexes and motion vectors of the reference frames of at least one pair of selected neighboring blocks are the same. Only when the image sequence indexes and motion vectors of the reference frames are the same is it determined that the angle direction is invalid, thereby making the judgment result more accurate.

[0252] Figure 21 This is a flowchart illustrating the tenth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily reflect that outcome. Figure 21 The illustrated process sequence is limited. For example... Figure 21 As shown, this embodiment may include:

[0253] S1010: Build a list of candidate neighboring blocks for the current block.

[0254] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0255] S1020: Set motion information for unavailable neighboring blocks.

[0256] S1030: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0257] S1040: Modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of unavailable neighboring blocks.

[0258] S1050: The current block is divided into multiple sub-blocks. Motion compensation is performed using the motion information of the corresponding neighboring blocks in the effective angular direction of each sub-block to obtain the predicted value of each sub-block.

[0259] The predicted values ​​of all sub-blocks constitute the predicted value of the current block, wherein the motion compensation of the sub-block in at least one effective angular direction uses the motion information of at least two corresponding neighboring blocks.

[0260] In one specific implementation, the current block is divided into a plurality of first sub-blocks of a first size, each first sub-block consisting of a plurality of second sub-blocks of a second size, and in at least one effective angular direction, the motion vector of at least one first sub-block is the weighted average of the motion vectors of at least two corresponding neighboring blocks.

[0261] Optionally, the first size is 8*8 and the second size is 4*4.

[0262] Combination Figure 22 The method for calculating the motion vectors of a first sub-block (8*8) in the horizontal and vertical directions is explained.

[0263] Two corresponding horizontal adjacent blocks (A) can be used to... K-1 and A K The weighted average of the motion vectors of the first sub-block is taken as the horizontal motion vector of the first sub-block. The specific calculation formula is as follows:

[0264]

[0265] Where MV_Hor is the motion vector of the first sub-block in the horizontal direction, MV(A k ) is A K The motion vector, MV(A) k-1 ) is A k-1 The motion vector.

[0266] Two corresponding vertical adjacent blocks (B) can be used to... K-1 and B K The weighted average of the motion vectors of the first sub-block is taken as the motion vector in the vertical direction. The specific calculation formula is as follows:

[0267]

[0268] Where MV_Ver is the motion vector of the first sub-block in the horizontal direction, MV(B k ) is B k The motion vector, MV(B) k-1 ) is B k-1 The motion vector.

[0269] The method described above for calculating the motion vectors of the first sub-block in the vertical and horizontal directions is also applicable when calculating the motion vectors of the first sub-block in other directions.

[0270] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0271] In this embodiment, motion information of at least two corresponding neighboring blocks is used when performing motion compensation for the first sub-block in the effective angular direction. Compared with the method of using motion information of only one corresponding neighboring block to perform motion compensation for the first sub-block, a more accurate prediction value of the first sub-block can be obtained, thereby improving the accuracy of encoding.

[0272] Figure 23 This is a flowchart illustrating the eleventh embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with a different result. Figure 23 The illustrated process sequence is limited. For example... Figure 23 As shown, this embodiment may include:

[0273] S1110: Build a list of candidate neighboring blocks for the current block.

[0274] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, of which the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0275] S1120: Set motion information for unavailable neighboring blocks.

[0276] S1130: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0277] S1140: Fill the effective angle direction into the angle pattern list to obtain the angle pattern index of the effective angle direction.

[0278] When angle mode inter-frame prediction and other inter-frame prediction modes are combined into a single mode index list, the index value of the angle mode index in the mode index list ranges from 4 to 8.

[0279] A separate mode list (i.e., an angle mode list) can be set up for the effective angles selected by the angle mode inter-frame prediction. After filling the angle mode list with the effective angle directions selected by the angle mode inter-frame prediction, the resulting angle mode index will have a value range of 0 to 4. Compared to sharing a mode index list with other modes, this requires fewer bits in subsequent encoding. Furthermore, isolating the angle mode index reduces the number of indices in the shared mode list.

[0280] S1150: Modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of unavailable neighboring blocks.

[0281] In addition, after obtaining the predicted value of the current block, it may also include:

[0282] S1160: Calculate the predicted value and rate-distortion cost of the current block using the motion information of neighboring blocks in each effective angular direction.

[0283] After calculating the prediction value and rate-distortion cost of the current block, rate-distortion cost optimization can be performed together with other inter-frame modes to select the optimal inter-frame prediction mode for encoding the current block. Therefore, based on this embodiment, the following steps may also be included:

[0284] S1170: Encode the current block to obtain the bitstream of the current block.

[0285] The current block's bitstream includes an angle mode flag, which indicates whether the current block uses angle mode inter-frame prediction.

[0286] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0287] Since the mode list corresponding to the selected inter-frame prediction mode needs to be encoded during the encoding process, in this embodiment, an independent angle mode list is set for angle mode inter-frame prediction. This can reduce the number of index lists in the original mode list, thereby reducing the length of the mode list that needs to be encoded during the encoding process and reducing the bit overhead (bit rate) required during the encoding process.

[0288] Figure 24 This is a flowchart illustrating the twelfth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with a different result. Figure 24 The illustrated process sequence is limited. For example... Figure 24 As shown, this embodiment may include:

[0289] S1210: Build a list of candidate neighboring blocks for the current block.

[0290] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, of which the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0291] S1220: Set motion information for unavailable neighboring blocks.

[0292] S1230: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0293] S1240: Determine the order of each effective angle direction using the texture direction of the current block.

[0294] The order of effective angle directions can be determined based on the gradient direction of the current block from the reference pixel. (See also...) Figure 25 S1240 may specifically include:

[0295] S1241: Calculate the gradient direction of the reference pixel in the current block using the gradient operator.

[0296] The reference pixel can be a reference pixel of the current block in intra-prediction mode. The reference pixel is located on the encoded side of the current block (e.g., the left and top sides). The gradient operator can be, but is not limited to, Roberts, Prewitt, Sobel, Laplacian, Canny, etc. The following uses the Sobel operator and the Laplacian operator as examples for illustration:

[0297] (1) The formula for calculating the gradient direction of the reference pixel in the current block using the Sobel operator is as follows:

[0298] S x =-a1f(x-1,y-1)-a2f(x-1,y)-a3f(x-1,y+1)+a1f(x+1,y-1)+a2f(x+1,y)+a3f(x+1,y+1)

[0299] S y =-a1f(x-1,y+1)-a2f(x,y+1)-a3f(x+1,y+1)+a1f(x-1,y-1)+a2f(x,y-1)+a3f(x+1,y-1)

[0300]

[0301] (2) The formula for calculating the gradient direction of the reference pixel in the current block using the Laplacian operator is as follows:

[0302] S x =a1(f(x-1,y)+f(x+1,y))-a2f(x,y)

[0303] Sy =a1(f(x,y-1)+f(x,y+1))-a2f(x,y)

[0304]

[0305] Where a1, a2, and a3 are constants, f(x,y) is the pixel value of the reference pixel, and S x S is the horizontal gradient of the reference pixel. y represents the vertical gradient of the reference pixel, and Angle represents the gradient direction of the reference pixel.

[0306] S1242: The number of reference pixels whose gradient direction falls within the angular range centered on each effective angular direction.

[0307] The size of the angle range can be determined according to actual needs. For example, the angle range centered on the horizontal direction can be 0°±15°, the angle range centered on the vertical direction can be 90°±15°, the angle range centered on the horizontal upward direction can be 135°±15°, the angle range centered on the horizontal downward direction can be -135°±15°, and the angle range centered on the vertical rightward direction can be 45°±15°.

[0308] S1243: Sort the effective angle directions in descending order of the number of reference pixels.

[0309] The effective angle directions are sorted in descending order of the number of reference pixels falling within the angle range.

[0310] S1250: Fill in the effective angle directions into the pattern list in sequence.

[0311] S1260: Modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of unavailable neighboring blocks.

[0312] S1270: Calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0313] For further detailed descriptions of the steps in this embodiment, please refer to the preceding embodiments, which will not be repeated here.

[0314] In this embodiment, based on selecting effective angle directions from multiple angles through a deduplication process, the order of each effective angle direction is further determined according to the texture direction. Specifically, the number of reference pixels in the current block whose gradient direction falls within the angle range centered on each effective angle direction is counted, and the effective angle directions are sorted in descending order of the number of falling reference pixels. Since effective angle directions with a larger number of corresponding reference pixels are closer to the texture direction of the current block, filling the pattern list with effective angle directions in order ensures that effective angle directions close to the texture direction of the current block are ranked higher in the pattern list, making them easier to select during encoding. This improves encoding accuracy and reduces the required bitrate.

[0315] Figure 26 This is a flowchart illustrating the thirteenth embodiment of the angle mode inter-frame prediction method of this application. It should be noted that if substantially the same result is obtained, this embodiment does not necessarily replace it with a different result. Figure 25 The illustrated process sequence is limited. For example... Figure 26 As shown, this embodiment may include:

[0316] S1301: Build a list of candidate neighboring blocks for the current block.

[0317] The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, of which the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks;

[0318] S1302: Set motion information for unavailable neighboring blocks.

[0319] S1303: Perform motion information deduplication on neighboring blocks in each angular direction, and the angular direction that passes the deduplication is the valid angular direction.

[0320] S1304: Modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of unavailable neighboring blocks.

[0321] S1305: The current block is divided into multiple sub-blocks. The motion information of each sub-block is obtained by using the motion information of the corresponding neighboring blocks in the effective angular direction.

[0322] Motion information includes motion vectors. Specifically, motion information can include forward motion information and backward motion information. Forward motion information can include a forward motion vector and a forward reference frame index, while backward motion information can include a backward motion vector and a backward reference frame index.

[0323] Each motion information of the current sub-block can be obtained by utilizing the motion information of its corresponding neighboring blocks in each effective angular direction.

[0324] S1306: The first predicted value of each sub-block is corrected by using multiple corrected motion vectors to obtain multiple second predicted values ​​for each sub-block.

[0325] The first predicted value is obtained by using motion information for motion compensation.

[0326] When the image order index of the forward reference frame and the image order index of the backward reference frame are the same for the current block, the first prediction value of each sub-block can be corrected using the decoder-side motion vector refinement (DMVR) technique to obtain multiple second prediction values ​​for each sub-block. Specifically:

[0327] refer to Figure 27 S1306 may include the following sub-steps:

[0328] S13061: The motion vector of each sub-block is corrected using multiple corrected motion vectors to obtain multiple corrected motion vectors for each sub-block.

[0329] The first predicted value, also known as the first predicted pixel value, can be obtained by compensating for each motion information of the current sub-block. The first predicted value can include a forward first predicted value and a backward first predicted value. The forward first predicted value can be obtained by motion compensation using forward motion information, and the backward first predicted value can be obtained by motion compensation using backward motion information.

[0330] The block corresponding to the first forward prediction value of the current sub-block can be called the first forward prediction block, and the block corresponding to the first backward prediction value of the current sub-block can be called the first backward prediction block. In other words, the block pointed to by the forward motion information of the current sub-block can be called the first forward prediction block, and the block pointed to by the backward motion information of the current sub-block can be called the first backward prediction block.

[0331] Multiple corrected motion vectors for each sub-block can be obtained by searching within the search range of the first prediction block in the forward / backward directions.

[0332] The search range of the first forward prediction block can be an N*N pixel range centered on the vertex of the first forward prediction block (the point where the top-left pixel is located). During the search, all pixels within the search range can be traversed in a predetermined order, such as traversing all pixels in the raster scan order from left to right and from top to bottom to obtain N. 2 A forward correction motion vector ΔMV1, where ΔMV1 is the motion vector from the vertex to the search pixel, or in other words, ΔMV1 is the motion vector from the first forward prediction block to the second forward prediction block (see the following explanation).

[0333] The search range for the backward first prediction block can be an N*N pixel range centered on the vertex of the backward first prediction block (the point where the bottom right pixel is located). During the search, all pixels within the search range can be traversed in a predetermined order to obtain N. 2 A backward correction motion vector is obtained by traversing all pixels in the raster scan order from right to left and from bottom to top. ΔMV2 is the motion vector from the vertex to the search pixel, or ΔMV1 is the motion vector from the backward first prediction block to the backward second prediction block.

[0334] To simplify the description, combined with Figure 28 The following explanation uses the example of obtaining the forward correction motion vector ΔMV1 within the search range of the first forward prediction block:

[0335] After finding search point C, the first forward prediction block is translated so that vertex A coincides with search point C, resulting in the second forward prediction block. Alternatively, when traversing to point C, a second forward prediction block with the same size as the sub-block and C as its vertex is formed. The predicted value of the second forward prediction block is then calculated. ΔMV1 is the motion vector from vertex A to search point C; or, ΔMV1 is the motion vector from the first forward prediction block containing vertex A to the second forward prediction block containing search point C.

[0336] The forward and backward correction motion vectors for each group are equal in magnitude but opposite in direction.

[0337] The forward motion vector of a sub-block can be corrected using the forward correction motion vector to obtain the corrected forward motion vector. Similarly, the backward motion vector of a sub-block can be corrected using the backward correction motion vector to obtain the corrected backward motion vector.

[0338] For example, if the motion vector of a sub-block is (MV1, MV2), then the corrected motion vector of the sub-block is (MV1+ΔMV1, MV2+ΔMV2).

[0339] S13062: Motion compensation is performed on each sub-block using multiple motion information containing corrected motion vectors to obtain multiple second prediction values ​​for each sub-block.

[0340] The second predicted value can be the pixel value of the second predicted block, which contains motion information of the corrected motion vector.

[0341] S1307: Select the corrected motion vector corresponding to the second predicted value with the smallest evaluation index for each sub-block as the final corrected motion vector for the sub-block.

[0342] The N of the sub-block can be obtained based on the Sum of Absolute Difference (SAD) algorithm. 2 For the evaluation index (SAD) between the forward second prediction value and the backward second prediction value, the correction motion vector corresponding to the pair of forward second prediction values ​​and backward second prediction values ​​with the smallest SAD is selected as the final correction motion vector of the sub-block.

[0343] S1308: Use the final corrected motion vectors of all sub-blocks to make corrections and obtain the corrected motion vectors.

[0344] S1309: Use the corrected motion vector to obtain the prediction value of each sub-block, and the prediction values ​​of all sub-blocks are combined to form the prediction value of the current block.

[0345] The predicted value of a sub-block is calculated using the corrected motion vector. The predicted value of a sub-block can be the average of the forward and backward predicted values.

[0346] For further detailed explanations of the steps in this embodiment, please refer to other embodiments, which will not be repeated here.

[0347] In this embodiment, before performing motion compensation on the motion information of the current block to obtain the predicted value, the motion vector of the current block is first corrected using DMWR technology, which can improve the accuracy of the prediction.

[0348] It should be noted that, provided they do not conflict with each other, the embodiments of this application can be combined.

[0349] Figure 29 This is a schematic diagram of the structure of a first embodiment of an angle-mode inter-frame prediction device according to this application. Figure 29 As shown, the device may include: a construction module 11, a setting module 12, a deduplication module 13, a modification module 14, and a calculation module 15.

[0350] The construction module 11 can be used to construct a candidate neighbor block list for the current block. The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0351] Setting module 12 can be used to set motion information for unavailable neighboring blocks.

[0352] The deduplication module 13 can be used to perform motion information deduplication on neighboring blocks in various angular directions, and the angular direction of the deduplication is the valid angular direction.

[0353] Modification module 14 is used to modify the motion information of unavailable neighbor blocks in the effective angle direction by utilizing the motion information of the reference block of the unavailable neighbor block in the effective angle direction.

[0354] The calculation module 15 can be used to calculate the predicted value of the current block using the motion information of the available and / or unavailable neighboring blocks in each effective angular direction.

[0355] Figure 30 This is a schematic diagram of the structure of a second embodiment of an angle-mode inter-frame prediction device according to this application. Figure 30 As shown, the device may include: a construction module 21, a setting module 22, a deduplication module 23, a modification module 24, and a calculation module 25. The construction module 21 can be used to construct a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, wherein the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0356] The setting module 22 can be used to set motion information for an unavailable neighboring block using the motion information of the time-domain co-block when the time-domain co-block of an unavailable neighboring block is available, and to set the initial value to the motion information of the unavailable neighboring block when the time-domain co-block of an unavailable neighboring block is unavailable.

[0357] The deduplication module 23 can be used to perform motion information deduplication on neighboring blocks in various angular directions, and the angular direction of the deduplication is the valid angular direction.

[0358] The modification module 24 can be used to modify the motion information of the available neighboring blocks whose motion information is the initial value, using the motion information of the reference block of the unavailable neighboring block whose motion information is the initial value.

[0359] The calculation module 25 can be used to calculate the predicted value of the current block using the motion information of the available and / or unavailable neighboring blocks in each effective angular direction.

[0360] Figure 31 This is a schematic diagram of the structure of a third embodiment of an angle-mode inter-frame prediction device according to this application. Figure 31 As shown, the device may include: a construction module 31, a setting module 32, a deduplication module 33, a modification module 34, and a calculation module 35.

[0361] The construction module 31 can be used to construct a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0362] Setting module 32 can be used to set motion information for unavailable neighboring blocks.

[0363] The deduplication module 33 is used to select at least one pair of neighboring blocks in each angular direction based on the size of the current block to perform motion information deduplication, and the angular direction of the deduplication is the valid angular direction.

[0364] Modification module 34 can be used to modify the motion information of available neighboring blocks by utilizing the motion information of reference blocks of unavailable neighboring blocks.

[0365] The calculation module 35 can be used to calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0366] Figure 32 This is a schematic diagram of the structure of a fourth embodiment of an angle-mode inter-frame prediction device according to this application. Figure 32 As shown, the device may include: a construction module 41, a setting module 42, a deduplication module 43, a modification module 44, and a calculation module 45.

[0367] The construction module 41 can be used to construct a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, wherein the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0368] Setting module 42 can be used to set motion information for unavailable neighboring blocks.

[0369] The deduplication module 43 can be used to perform motion information deduplication on neighboring blocks in various angular directions. The angular direction that is deduplicated is the valid angular direction. If the angular direction meets the first condition, at least one deduplication is added.

[0370] Modification module 44 can be used to modify the motion information of unavailable neighboring blocks by utilizing the motion information of the reference blocks of unavailable neighboring blocks;

[0371] The calculation module 45 can be used to calculate the predicted value of the current block using the motion information of the available and / or unavailable neighboring blocks in each effective angular direction.

[0372] Figure 33 This is a schematic diagram of the structure of a fifth embodiment of an angle mode inter-frame prediction device according to this application. Figure 33 As shown, the device may include: a construction module 51, a setting module 52, a deduplication module 53, a modification module 54, and a calculation module 55.

[0373] The construction module 51 can be used to construct a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0374] Setting module 52 can be used to set motion information for unavailable neighboring blocks.

[0375] The deduplication module 53 can be used to perform motion information deduplication on neighboring blocks in various angular directions. The angular direction of the deduplication is the valid angular direction. If at least two of the horizontal, vertical and horizontal upward deduplication results meet the second condition, then at least one horizontal upward deduplication is reduced.

[0376] Modification module 54 can be used to modify the motion information of unavailable neighboring blocks by utilizing the motion information of the reference blocks of unavailable neighboring blocks.

[0377] The calculation module 55 can be used to calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0378] Figure 34 This is a schematic diagram of the sixth embodiment of an angle-mode inter-frame prediction device according to this application. Figure 34 As shown, the device may include: a construction module 61, a setting module 62, a deduplication module 63, a modification module 64, and a calculation module 65.

[0379] Module 61 is used to build a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0380] Setting module 62 can be used to set motion information for unavailable neighboring blocks.

[0381] The deduplication module 63 can be used to perform motion information deduplication on neighboring blocks in various angular directions. The angular direction used for deduplication is the valid angular direction. The deduplication includes determining whether the image sequence index of the reference frames of at least one pair of selected neighboring blocks is the same and whether the motion is the same.

[0382] Modification module 64 can be used to modify the motion information of unavailable neighboring blocks by utilizing the motion information of the reference blocks of unavailable neighboring blocks.

[0383] The calculation module 65 can be used to calculate the predicted value of the current block using the motion information of the available and / or unavailable neighboring blocks in each effective angular direction.

[0384] Figure 35 This is a schematic diagram of the structure of a seventh embodiment of an angle mode inter-frame prediction device according to this application. Figure 35 As shown, the device may include: a construction module 71, a setting module 72, a deduplication module 73, a modification module 74, and a calculation module 75.

[0385] Module 71 is used to build a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0386] Setting module 72 can be used to set motion information for unavailable neighboring blocks.

[0387] The deduplication module 73 can be used to perform motion information deduplication on neighboring blocks in various angular directions, and the angular direction of the deduplication is the valid angular direction.

[0388] Modification module 74 can be used to modify the motion information of unavailable neighboring blocks by utilizing the motion information of the reference blocks of unavailable neighboring blocks.

[0389] The calculation module 75 can be used to perform motion compensation by using the motion information of the corresponding neighboring blocks of each sub-block in the effective angular direction when the current block is divided into multiple sub-blocks, to obtain the predicted value of each sub-block, and the predicted values ​​of all sub-blocks constitute the predicted value of the current block, wherein the motion compensation of at least one sub-block in the effective angular direction uses the motion information of at least two corresponding neighboring blocks.

[0390] Figure 36 This is a schematic diagram of the structure of the eighth embodiment of an angle mode inter-frame prediction device according to this application. Figure 36 As shown, the device may include: a construction module 81, a setting module 82, a deduplication module 83, an input module 84, a modification module 85, and a calculation module 86.

[0391] The construction module 81 can be used to construct a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0392] Setting module 82 can be used to set motion information for unavailable neighboring blocks.

[0393] The deduplication module 83 can be used to perform motion information deduplication on neighboring blocks in various angular directions, and the angular direction of the deduplication is the valid angular direction.

[0394] The fill module 84 can be used to fill the valid angle direction into the angle pattern list and obtain the angle pattern index of the valid angle direction.

[0395] Modification module 85 can be used to modify the motion information of unavailable neighboring blocks by utilizing the motion information of the reference blocks of unavailable neighboring blocks.

[0396] The calculation module 86 can be used to calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0397] Figure 37 This is a schematic diagram of the structure of the ninth embodiment of an angle mode inter-frame prediction device according to this application. Figure 37 As shown, the device may include: a construction module 91, a setting module 92, a deduplication module 93, a determination module 94, a filling module 95, a modification module 96, and a calculation module 97.

[0398] The construction module 91 can be used to construct a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0399] Setting module 92 can be used to set motion information for unavailable neighboring blocks.

[0400] The deduplication module 93 can be used to perform motion information deduplication on neighboring blocks in various angular directions, and the angular direction of the deduplication is the valid angular direction.

[0401] The determination module 94 can be used to determine the order of each effective angular direction using the texture direction of the current block.

[0402] The fill module 95 can be used to fill the valid angle directions into the pattern list in sequence.

[0403] Modification module 96 can be used to modify the motion information of unavailable neighboring blocks by utilizing the motion information of the reference blocks of unavailable neighboring blocks.

[0404] The calculation module 97 can be used to calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in each effective angular direction.

[0405] Figure 38 This is a schematic diagram of the tenth embodiment of an angle-mode inter-frame prediction device according to this application. Figure 38 As shown, the device may include: a construction module 101, a setting module 102, a deduplication module 103, a modification module 104, a first calculation module 105, a first correction module 106, a selection module 107, a second correction module 108, and a second calculation module 109.

[0406] The construction module 101 can be used to construct a candidate neighbor list for the current block. The candidate neighbor list includes neighbor blocks of the current block in multiple angular directions, where the encoded neighbor blocks using inter-frame prediction are available neighbor blocks, and the remaining neighbor blocks are unavailable neighbor blocks.

[0407] The setting module 102 can be used to set motion information for unavailable neighboring blocks.

[0408] The deduplication module 103 can be used to perform motion information deduplication on neighboring blocks in various angular directions, and the angular direction of the deduplication is the valid angular direction.

[0409] The modification module 104 can be used to modify the motion information of unavailable neighboring blocks by utilizing the motion information of the reference blocks of unavailable neighboring blocks.

[0410] The first calculation module 105 can be used to obtain the motion information of each sub-block by using the motion information of the corresponding neighboring blocks in the effective angular direction when the current block is divided into multiple sub-blocks. The motion information includes motion vectors.

[0411] The first correction module 106 can be used to correct the first predicted value of each sub-block using multiple correction motion vectors to obtain multiple second predicted values ​​for each sub-block. The first predicted value is obtained by motion compensation using motion information.

[0412] The selection module 107 can be used to select the corrected motion vector corresponding to the second predicted value with the smallest evaluation index for each sub-block, as the final corrected motion vector of the sub-block;

[0413] The second correction module 108 can be used to correct the motion vector by utilizing the final correction motion vector of all sub-blocks, and obtain the corrected motion vector.

[0414] The second calculation module 109 can be used to obtain the prediction value of each sub-block using motion information containing the corrected motion vector, and the prediction values ​​of all the sub-blocks constitute the prediction value of the current block.

[0415] Figure 39 This is a schematic diagram of the structure of an embodiment of the encoder of this application. Figure 39 As shown, the encoder includes a processor 111 and a memory 112 coupled to the processor.

[0416] The memory 112 stores program instructions for implementing the methods of any of the above embodiments; the processor 111 executes the program instructions stored in the memory 112 to implement the steps of the above method embodiments. The processor 111 may also be referred to as a CPU (Central Processing Unit). The processor 111 may be an integrated circuit chip with signal processing capabilities. The processor 111 may also be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The general-purpose processor may be a microprocessor or any conventional processor.

[0417] Figure 40This is a schematic diagram of the structure of an embodiment of the storage medium of this application. Figure 40 As shown, the storage medium 120 in this embodiment stores program instructions 121, which, when executed, implement the methods provided in the above embodiments of this application. The program instructions 121 can form a program file and be stored in the storage medium 120 as a software product, causing a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute all or part of the steps of the methods in the various embodiments of this application. The aforementioned storage medium 1400 includes various media capable of storing program code, such as a USB flash drive, portable hard drive, read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk, or terminal devices such as computers, servers, mobile phones, and tablets.

[0418] Figure 41 A schematic diagram of the structure of an embodiment of the electronic device of this application. (See diagram below.) Figure 41 As shown, the electronic device 130 may include, but is not limited to, encoder 131 (the encoder 121 mentioned above), or other encoders capable of implementing the above method steps, without specific limitations here.

[0419] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, or indirect coupling or communication connection between apparatuses or units, and may be electrical, mechanical, or other forms.

[0420] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated units described above can be implemented in hardware or as software functional units. The above are merely embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made based on the description and drawings of this application, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.

Claims

1. An angle-mode inter-frame prediction method, characterized in that, include: Construct a candidate neighbor block list for the current block, the candidate neighbor block list including the neighbor blocks of the current block in multiple angular directions, wherein the available neighbor blocks are the coded neighbor blocks using inter-frame prediction, and the remaining neighbor blocks are unavailable neighbor blocks; Configure the settings to allow motion information from unavailable neighboring blocks; The motion information of the neighboring blocks in each angular direction is checked for duplicates, and the angular direction that has passed the duplicate check is the valid angular direction; Fill the effective angle direction into the angle pattern list to obtain the angle pattern index of the effective angle direction; The motion information of the unavailable neighboring block is modified using the motion information of the reference block of the unavailable neighboring block; the reference block of the unavailable neighboring block includes the previous neighboring block and / or the next neighboring block of the unavailable neighboring block; The predicted value of the current block is calculated using the motion information of available and / or unavailable neighboring blocks in the effective angular direction.

2. The method according to claim 1, characterized in that, The angle pattern index has a value range of 0 to 4.

3. The method according to claim 1, characterized in that, The current block's bitstream includes an angle mode marker, which indicates whether the current block uses the angle mode for inter-frame prediction.

4. The method according to claim 1, characterized in that, The motion information deduplication of the neighboring blocks in each angular direction includes: Based on the size of the current block, at least one pair of neighboring blocks are selected in each angular direction for motion information deduplication.

5. The method according to claim 1, characterized in that, Calculating the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in the effective angular direction includes: The current block is divided into multiple sub-blocks. Motion compensation is performed using the motion information of the corresponding neighboring blocks of each sub-block in the effective angular direction to obtain the predicted value of each sub-block. The predicted values ​​of all sub-blocks of the current block constitute the predicted value of the current block.

6. The method according to claim 5, characterized in that, The process of using the motion information of the corresponding neighboring blocks of each sub-block in the effective angular direction to perform motion compensation and obtain the predicted value of each sub-block includes: The first predicted value of each sub-block is corrected using multiple corrected motion vectors to obtain multiple second predicted values ​​for each sub-block; the first predicted value of each sub-block is obtained by motion compensation using the motion information of each sub-block, and the motion information of each sub-block is obtained by using the motion information of the corresponding neighboring blocks of each sub-block in the effective angular direction; The final corrected motion vector for each sub-block is determined based on the corrected motion vector corresponding to the second predicted value with the smallest evaluation index for each sub-block. The final corrected motion vector of each sub-block is used for correction to obtain the corrected motion vector; The predicted value for each sub-block is determined using the corrected motion vectors.

7. The method according to claim 6, characterized in that, The corrected motion vector includes a forward corrected motion vector and a backward corrected motion vector. The second predicted value includes a forward second predicted value and a backward second predicted value. The forward second predicted value is the pixel value of the second predicted block pointed to by the motion information of the corrected forward motion vector. The corrected forward motion vector is obtained by correcting the forward motion vector of the sub-block using the forward corrected motion vector. The backward second predicted value is the pixel value of the second predicted block pointed to by the motion information of the corrected backward motion vector. The corrected backward motion vector is obtained by correcting the backward motion vector of the sub-block using the backward corrected motion vector. The determination of the final corrected motion vector for each sub-block, based on the corrected motion vector corresponding to the second predicted value with the minimum evaluation index for each sub-block, includes: Based on the absolute error and algorithm, an evaluation index is obtained between the forward second prediction value and the backward second prediction value of each corrected motion vector of each sub-block. The final corrected motion vector of the sub-block is determined based on the corrected motion vector corresponding to the pair of forward and backward second predicted values ​​that have the smallest evaluation index.

8. The method according to claim 7, characterized in that, The forward and backward correction motion vectors for each group are equal in magnitude and opposite in direction; and / or, The predicted value of the sub-block is the average of the forward and backward predicted values ​​of the sub-block.

9. The method according to claim 1, characterized in that, The modification of the motion information of unavailable neighboring blocks using the motion information of reference blocks of unavailable neighboring blocks further includes: Set the motion information of the unavailable neighboring blocks to the initial value.

10. The method according to claim 1, characterized in that, All of the neighboring blocks are the same size and smaller than the current block; and / or, the neighboring blocks are located to the left or above the current block.

11. The method according to any one of claims 1-10, characterized in that, The plurality of angular directions include at least two of the following: horizontal, vertical, horizontal upward, horizontal downward, and vertical to the right.

12. An angle-mode inter-frame prediction device, characterized in that, include: A construction module is used to construct a candidate neighbor block list for the current block. The candidate neighbor block list includes neighbor blocks of the current block in multiple angular directions, wherein the available neighbor blocks are the coded neighbor blocks using inter-frame prediction, and the remaining neighbor blocks are unavailable neighbor blocks. The deduplication module is used to perform motion information deduplication on the neighboring blocks in each angular direction. The angular direction that has passed the deduplication is the valid angular direction. The settings module is used to configure motion information for unavailable neighboring blocks; The input module is used to input the effective angle direction into the angle pattern list to obtain the angle pattern index of the effective angle direction. The modification module is used to modify the motion information of unavailable neighboring blocks using the motion information of the reference blocks of the unavailable neighboring blocks; the reference blocks of the unavailable neighboring blocks include the previous neighboring block and / or the next neighboring block of the unavailable neighboring block; The calculation module is used to calculate the predicted value of the current block using the motion information of available and / or unavailable neighboring blocks in the effective angular direction.

13. An encoder, characterized in that, The encoder includes a processor and a memory connected to the processor, wherein... The memory stores program instructions; The processor is used to execute program instructions stored in the memory to implement the method as described in any one of claims 1-11.

14. A storage medium, characterized in that, The storage medium stores program instructions that, when executed by a processor, implement the method as described in any one of claims 1-11.

15. An electronic device, characterized in that, Includes the encoder as described in claim 13.

Citation Information

Patent Citations

  • Motion information exporting method and device in video coding and decoding

    CN103024378A

  • Encoding method and decoding method

    CN103782599A