IP Library Granted Patent US 12689745
Granted Patent B2
US 12689745 · App. 18/596,614 · Granted Jul 21, 2026

Candidate derivation for affine merge mode in video coding

Inventors: Wei Chen (San Diego, CA); Xiaoyu Xiu (San Diego, CA); Yi-Wen Chen (San Diego, CA); Hong-Jheng Jhu (San Diego, CA); Che-Wei Kuo (San Diego, CA); Ning Yan (San Diego, CA); Xianglin Wang (San Diego, CA); Bing Yu (Beijing, CN)
Assignee: BEIJING DAJIA INTERNET INFORMATION TECHNOLOGY CO., LTD.
H04N19/176H04N19/129H04N19/139
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12689745
App. No.
18/596,614
Granted
Jul 21, 2026
Kind
B2
Abstract

A method of video coding, an apparatus, and a non-transitory computer-readable storage medium thereof are provided. The method includes obtaining one or more affine candidates from a plurality of non-adjacent neighbor blocks that are non-adjacent to a current block. The method may further include obtaining one or more control point motion vectors (CPMVs) for the current block based on the one or more affine candidates.

Claims (94)

1 . A method of video decoding, comprising:

obtaining one or more affine candidates from a plurality of non-adjacent neighbor blocks that are non-adjacent to a current block according to a scanning rule; and

obtaining one or more control point motion vectors (CPMVs) for the current block based on the one or more affine candidates,

wherein the method further comprises:

scanning a plurality of non-adjacent neighbor blocks in a first scanning area to obtain one or more non-adjacent neighbor blocks coded with affine mode;

determining the one or more non-adjacent neighbor blocks coded with affine mode as the one or more affine candidates; and

in response to determining that a number of the one or more non-adjacent neighbor blocks coded with affine mode obtained reaches a predefined number, stopping scanning in the first scanning area,

wherein the scanning rule is determined based on at least one scanning area, at least one scanning distance, and a scanning order, and the at least one scanning distance indicates a number of blocks away from a side of the current block.

2 . The method of claim 1 , further comprising:

scanning from a first starting non-adjacent neighbor block along a scanning line parallel with a left side of the current block, wherein the first starting non-adjacent neighbor block is a bottom block in the first scanning area, blocks in the first scanning area are at a first scanning distance away from the left side of the current block,

wherein the first starting non-adjacent neighbor block is on the bottom and the left of a second starting non-adjacent neighbor block in a second scanning area, blocks in the second scanning area are at a second scanning distance away from the left side of the current block.

3 . The method of claim 1 , further comprising:

scanning from a third starting non-adjacent neighbor block along a scanning line parallel with an upper side of the current block, wherein the third starting non-adjacent neighbor block is a right block in the first scanning area, blocks in the first scanning area are at a first scanning distance away from the upper side of the current block,

wherein the third starting non-adjacent block is on the top and the right of a fourth starting non-adjacent neighbor block in a second scanning area, blocks in the second scanning area are at a second scanning distance away from the upper side of the current block.

4 . The method of claim 1 , wherein the at least one scanning area comprises at least one left scanning area that is on the left of the current block and at least one upper scanning area that is above the current block;

the method further comprises:

scanning a plurality of first non-adjacent neighbor blocks in the at least one left scanning area to obtain one or more first non-adjacent neighbor blocks coded with affine mode;

scanning a plurality of second non-adjacent neighbor blocks in the at least one upper scanning area to obtain one or more second non-adjacent neighbor blocks coded with affine mode; and

determining the one or more first non-adjacent neighbor blocks coded with affine mode and the one or more second non-adjacent neighbor blocks coded with affine mode as the one or more affine candidates.

5 . The method of claim 4 , wherein the at least one left scanning area comprises a first left scanning area, a second left scanning area, and a third left scanning area,

wherein blocks in the first left scanning area are at a first scanning distance away from a left side of the current block, blocks in the second left scanning area are at a second scanning distance away from the left side of the current block, and

blocks in the third left scanning area are at a third scanning distance away from the left side of the current block, and

wherein scanning the plurality of first non-adjacent neighbor blocks in the at least one left scanning area comprises:

scanning from a first starting non-adjacent neighbor block along a first scanning line parallel with the left side of the current block, wherein the first starting non-adjacent neighbor block is a bottom block in the first left scanning area;

scanning from a second starting non-adjacent neighbor block along a second scanning line parallel with the left side of the current block, wherein the second starting non-adjacent neighbor block is a bottom block in the second left scanning area; and

scanning from a third starting non-adjacent neighbor block along a third scanning line parallel with the left side of the current block, wherein the third starting non-adjacent neighbor block is a bottom block in the third left scanning area.

6 . The method of claim 5 , wherein the at least one upper scanning area comprises a first upper scanning area, a second upper scanning area, and a third upper scanning area,

wherein blocks in the first upper scanning area are at a first scanning distance away from an upper side of the current block, blocks in the second upper scanning area are at a second scanning distance away from the upper side of the current block, and blocks in the third upper scanning area are at a third scanning distance away from the upper side of the current block, and

wherein scanning the plurality of second non-adjacent neighbor blocks in the at least one upper scanning area comprises:

scanning from a fourth starting non-adjacent neighbor block along a fourth scanning line parallel with the upper side of the current block, wherein the fourth starting non-adjacent neighbor block is a right block in the first upper scanning area;

scanning from a fifth starting non-adjacent neighbor block along a fifth scanning line parallel with the upper side of the current block, wherein the fifth starting non-adjacent neighbor block is a right block in the second upper scanning area; and

scanning from a sixth starting non-adjacent neighbor block along a sixth scanning line parallel with the upper side of the current block, wherein the sixth starting non-adjacent neighbor block is a right block in the third upper scanning area,

wherein the first scanning distance is smaller than the second distance, and the second scanning distance is smaller than the third scanning distance.

7 . The method of claim 1 , further comprising:

obtaining a first candidate position for a first affine candidate and a second candidate position for a second affine candidate based on a scanning rule;

determining a third candidate position for a third affine candidate based on the first and second candidate positions for the third affine candidate;

obtaining a virtual block based on the first candidate position, the second candidate position, and the third candidate position;

obtaining three CPMVs for the virtual block based on translational motion vectors (MVs) at the first candidate position, the second candidate position, and the third candidate position; and

obtaining two or three CPMVs for the current block based on the three CPMVs of the virtual block by using a same projection process configured for inherited candidate derivation,

wherein the virtual block is a rectangular coding block and the third candidate position is determined based on a vertical position of the first candidate position and a horizontal position of the second candidate position,

wherein the scanning rule is determined based on at least one scanning area, at least one scanning direction, at least one scanning distance, and a scanning order.

8 . The method of claim 7 , further comprising:

obtaining the first candidate position by scanning in a first scanning area along a first scanning direction perpendicular to an upper side of the current block at a first scanning distance, wherein the first scanning distance comprises a first number of motion fields, a distance between the first candidate position and an adjacent motion field on the right of and above the upper side is the first scanning distance, and the first scanning area comprises a line of continuous motion fields on the right of and above the upper side; and

obtaining the second candidate position by scanning in a second scanning area along a second scanning direction perpendicular to a left side of the current block at a second scanning distance, wherein the second scanning distance comprises a second number of motion fields, a distance between the second candidate position and an adjacent motion field on the left and bottom of the left side is the second scanning distance, and the second scanning area comprises a line of continuous motion fields on the left and bottom of the left side.

9 . The method of claim 8 , further comprising:

scanning in the first scanning area or in the second scanning area in a scanning order facing away from the current block.

10 . The method of claim 7 , further comprising:

obtaining the first candidate position by scanning in a third scanning area along a third scanning direction parallel to an upper side of the current block at a third scanning distance; and

obtaining the second candidate position by scanning in a fourth scanning area along a fourth scanning direction parallel to a left side of the current block at a fourth scanning distance.

11 . The method of claim 10 , further comprising:

scanning in the third scanning area in a scanning order from left to right; and

scanning in the fourth scanning area in a scanning order from top to down.

12 . The method of claim 7 , further comprising:

obtaining the first candidate position by scanning in a fifth scanning area along a combination of a third scanning direction parallel to an upper side of the current block and a first scanning direction perpendicular to the upper side at a fifth scanning distance;

obtaining the second candidate position by scanning in a sixth scanning area along a combination of a fourth scanning direction parallel to a left side of the current block and a second scanning direction perpendicular to the left side at a sixth scanning distance.

13 . The method of claim 12 , further comprising:

scanning in the fifth scanning area in a combined scanning order from left to right and facing away from the current block; and

scanning in the sixth scanning area in a combined scanning order from top to down and facing away from the current block.

14 . The method of claim 7 , further comprising:

in response to determining that a number of the one or more affine candidates reaches a predefined number, stopping scanning in the at least one scanning area.

15 . The method of claim 7 , further comprising:

in response to determining that motion information of the first, second, and third affine candidates is available, determining that the virtual block represents a 6-parameter affine model;

in response to determining that motion information of one of the first, second, and third affine candidates is unavailable, determining that the virtual block represents a 4-parameter affine model; and

in response to determining that motion information of more than one of the first, second, and third affine candidates is unavailable, determining that the virtual block is not capable of representing a valid affine model.

16 . An apparatus for video coding, comprising:

one or more processors; and

a memory coupled to the one or more processors and configured to store instructions executable by the one or more processors,

wherein the one or more processors, upon execution of the instructions, are configured to perform operations comprising:

obtaining one or more affine candidates from a plurality of non-adjacent neighbor blocks that are non-adjacent to a current block by scanning the plurality of non-adjacent neighbor blocks in at least one scanning area according to a scanning rule; and

obtaining one or more control point motion vectors (CPMVs) for the current block based on the one or more affine candidates,

wherein the operations further comprise:

scanning a plurality of non-adjacent neighbor blocks in a first scanning area to obtain one or more non-adjacent neighbor blocks coded with affine mode;

determining the one or more non-adjacent neighbor blocks coded with affine mode as the one or more affine candidates; and

in response to determining that a number of the one or more non-adjacent neighbor blocks coded with affine mode obtained reaches a predefined number, stopping scanning in the first scanning area,

wherein the at least one scanning area consists of at least one line of continuous blocks, the scanning rule is determined based on at least one scanning area, at least one scanning distance, and a scanning order, and the at least one scanning distance indicates a number of blocks away from a side of the current block.

17 . A non-transitory computer-readable storage medium storing a bitstream and executable instructions that when executed by one or more processors, cause the one or more processors to perform operations comprising:

obtaining one or more affine candidates from a plurality of non-adjacent neighbor blocks that are non-adjacent to a current block by scanning the plurality of non-adjacent neighbor blocks in at least one scanning area according to a scanning rule; and

obtaining one or more control point motion vectors (CPMVs) for the current block based on the one or more affine candidates,

wherein the operations further comprise:

scanning a plurality of non-adjacent neighbor blocks in a first scanning area to obtain one or more non-adjacent neighbor blocks coded with affine mode;

determining the one or more non-adjacent neighbor blocks coded with affine mode as the one or more affine candidates; and

in response to determining that a number of the one or more non-adjacent neighbor blocks coded with affine mode obtained reaches a predefined number, stopping scanning in the first scanning area,

wherein the at least one scanning area consists of at least one line of continuous blocks, the scanning rule is determined based on at least one scanning area, at least one scanning distance, and a scanning order, and the at least one scanning distance indicates a number of blocks away from a side of the current block.

18 . The apparatus of claim 16 , wherein the operations further comprise:

scanning from a first starting non-adjacent neighbor block along a scanning line parallel with a left side of the current block, wherein the first starting non-adjacent neighbor block is a bottom block in the first scanning area, blocks in the first scanning area are at a first scanning distance away from the left side of the current block,

wherein the first starting non-adjacent neighbor block is on the bottom and the left of a second starting non-adjacent neighbor block in a second scanning area, blocks in the second scanning area are at a second scanning distance away from the left side of the current block.

19 . The apparatus of claim 16 , wherein the operations further comprise:

scanning from a third starting non-adjacent neighbor block along a scanning line parallel with an upper side of the current block, wherein the third starting non-adjacent neighbor block is a right block in the first scanning area, blocks in the first scanning area are at a first scanning distance away from the upper side of the current block,

wherein the third starting non-adjacent block is on the top and the right of a fourth starting non-adjacent neighbor block in a second scanning area, blocks in the second scanning area are at a second scanning distance away from the upper side of the current block.

20 . The apparatus of claim 16 , wherein the at least one scanning area comprises at least one left scanning area that is on the left of the current block and at least one upper scanning area that is above the current block;

the operations further comprise:

scanning a plurality of first non-adjacent neighbor blocks in the at least one left scanning area to obtain one or more first non-adjacent neighbor blocks coded with affine mode;

scanning a plurality of second non-adjacent neighbor blocks in the at least one upper scanning area to obtain one or more second non-adjacent neighbor blocks coded with affine mode; and

determining the one or more first non-adjacent neighbor blocks coded with affine mode and the one or more second non-adjacent neighbor blocks coded with affine mode as the one or more affine candidates.