Skip to content
  • David Barker's avatar
    [jnt-comp, normative] Avoid double-rounding in prediction · 39cf8061
    David Barker authored
    As per the linked bug report, the distance-weighted compound
    prediction has two separate round operations, first by 3
    bits (inside the various convolve functions), then by 10 bits
    (after the convolution functions).
    
    We can improve on this by right shifting by 3 bits inside the
    convolve functions - this is equivalent to doing a single round
    by 13 bits at the end.
    
    Note: In the encoder, when doing joint_motion_search(), we do
    things a bit differently: So that we can try modifying the two
    "sides" of the prediction independently, we predict each side as
    if it were a single prediction (including rounding), then blend
    these single predictions together.
    
    This is already an approximation to the "real" prediction, even
    in the non-jnt-comp case. So we leave that code path as-is.
    
    BUG=aomedia:1289
    
    Change-Id: I9ad1fbcb3e12db2b5fc3c82b407f0fd9e6b39750
    39cf8061