| CPC H04N 19/527 (2014.11) [H04N 19/105 (2014.11); H04N 19/132 (2014.11); H04N 19/159 (2014.11); H04N 19/176 (2014.11)] | 15 Claims |

|
1. A method of video encoding, comprising:
obtaining a first reference picture and a second reference picture associated with a current coding block of a current picture, wherein the first reference picture is before the current picture and the second reference picture is after the current picture in time order;
obtaining a first prediction based on a first motion vector from the current coding block to a reference block in the first reference picture;
obtaining a second prediction based on a second motion vector from the current coding block to a reference block in the second reference picture; and
calculating a bi-prediction of the current coding block based on at least the first prediction and the second prediction, comprising: enabling a bidirectional optical flow (BDOF) in calculating the bi-prediction of the current coding block on a condition that a Combined Inter and Intra Prediction (CIIP) is not applied to calculate the bi-prediction of the current coding block, wherein the BDOF comprises:
calculating first horizontal gradient values
![]() and first vertical gradient values
![]() for prediction samples associated with the first prediction, and calculating second horizontal gradient values
![]() and second vertical gradient values
![]() for prediction samples associated with the second prediction, wherein I(0)(i,j) represents the prediction sample at sample location (i,j) associated with the first prediction, and I(1)(i,j) represents the prediction sample at sample location (i,j) associated with the second prediction; and
calculating the bi-prediction of the current coding block based on the first prediction, the second prediction, the first horizontal gradient values, the first vertical gradient values, the second horizontal gradient values, and the second vertical gradient values.
|