Commit bec4fbe4 authored by Sarah Parker's avatar Sarah Parker

Switch order of gm parameters for affine model

This was originally subtracting 1 from the wrong element in the
parameter set.

Change-Id: I790aafc505f7a8fe7bb00d7d6c62549487a0980f
parent 253c001f
......@@ -3387,11 +3387,11 @@ static void read_global_motion_params(Global_Motion_Params *params,
case GLOBAL_AFFINE:
params->motion_params.wmmat[4] =
(vp10_read_primitive_symmetric(r, GM_ABS_ALPHA_BITS) *
GM_ALPHA_DECODE_FACTOR) +
(1 << WARPEDMODEL_PREC_BITS);
GM_ALPHA_DECODE_FACTOR);
params->motion_params.wmmat[5] =
vp10_read_primitive_symmetric(r, GM_ABS_ALPHA_BITS) *
GM_ALPHA_DECODE_FACTOR;
GM_ALPHA_DECODE_FACTOR +
(1 << WARPEDMODEL_PREC_BITS);
// fallthrough intended
case GLOBAL_ROTZOOM:
params->motion_params.wmmat[2] =
......
......@@ -3155,11 +3155,11 @@ static void write_global_motion_params(Global_Motion_Params *params,
case GLOBAL_ZERO: break;
case GLOBAL_AFFINE:
vp10_write_primitive_symmetric(
w, (params->motion_params.wmmat[4] * GM_ALPHA_ENCODE_FACTOR) -
(1 << GM_ALPHA_PREC_BITS),
w, params->motion_params.wmmat[4] * GM_ALPHA_ENCODE_FACTOR,
GM_ABS_ALPHA_BITS);
vp10_write_primitive_symmetric(
w, params->motion_params.wmmat[5] * GM_ALPHA_ENCODE_FACTOR,
w, (params->motion_params.wmmat[5] * GM_ALPHA_ENCODE_FACTOR) -
(1 << GM_ALPHA_PREC_BITS),
GM_ABS_ALPHA_BITS);
// fallthrough intended
case GLOBAL_ROTZOOM:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment