Commit d3409bad authored by Debargha Mukherjee's avatar Debargha Mukherjee

Fix a spatial svc bug related to scaling

Fixes bug introduced in
https://chromium-review.googlesource.com/#/c/299482/5

Change-Id: If542c1a917380465dd9bc4ce5e32b0adbb20e340
parent f78b7dae
...@@ -3682,12 +3682,16 @@ YV12_BUFFER_CONFIG *vp9_scale_if_required(VP9_COMMON *cm, ...@@ -3682,12 +3682,16 @@ YV12_BUFFER_CONFIG *vp9_scale_if_required(VP9_COMMON *cm,
if (cm->mi_cols * MI_SIZE != unscaled->y_width || if (cm->mi_cols * MI_SIZE != unscaled->y_width ||
cm->mi_rows * MI_SIZE != unscaled->y_height) { cm->mi_rows * MI_SIZE != unscaled->y_height) {
#if CONFIG_VP9_HIGHBITDEPTH #if CONFIG_VP9_HIGHBITDEPTH
if (use_normative_scaler) if (use_normative_scaler &&
unscaled->y_width <= (scaled->y_width << 1) &&
unscaled->y_height <= (scaled->y_height << 1))
scale_and_extend_frame(unscaled, scaled, (int)cm->bit_depth); scale_and_extend_frame(unscaled, scaled, (int)cm->bit_depth);
else else
scale_and_extend_frame_nonnormative(unscaled, scaled, (int)cm->bit_depth); scale_and_extend_frame_nonnormative(unscaled, scaled, (int)cm->bit_depth);
#else #else
if (use_normative_scaler) if (use_normative_scaler &&
unscaled->y_width <= (scaled->y_width << 1) &&
unscaled->y_height <= (scaled->y_height << 1))
scale_and_extend_frame(unscaled, scaled); scale_and_extend_frame(unscaled, scaled);
else else
scale_and_extend_frame_nonnormative(unscaled, scaled); scale_and_extend_frame_nonnormative(unscaled, scaled);
......
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