Commit 9ead3b8c authored by Luc Trudeau's avatar Luc Trudeau

Remove duplicate code in reconinter.c

Pull out the identical code block that declares tmp_dst2 with or without
CONFIG_HIGHBITDEPTH and stick it at the front of there.

Change-Id: I69787875f6d67281c9b3c0df99c1eda6a168f426
parent 030ff74d
......@@ -974,13 +974,13 @@ void av1_make_masked_inter_predictor(const uint8_t *pre, int pre_stride,
mi->mbmi.interinter_compound_type
};
#if CONFIG_HIGHBITDEPTH
#if CONFIG_CONVOLVE_ROUND
const int is_conv_no_round = conv_params->round == CONVOLVE_OPT_NO_ROUND;
DECLARE_ALIGNED(16, CONV_BUF_TYPE, tmp_dst2[MAX_SB_SQUARE]);
int tmp_dst2_stride = MAX_SB_SIZE;
CONV_BUF_TYPE *org_dst = conv_params->dst;
int org_dst_stride = conv_params->dst_stride;
#if CONFIG_HIGHBITDEPTH
#if CONFIG_CONVOLVE_ROUND
if (is_conv_no_round) {
conv_params->dst = tmp_dst2;
conv_params->dst_stride = tmp_dst2_stride;
......@@ -1070,11 +1070,6 @@ void av1_make_masked_inter_predictor(const uint8_t *pre, int pre_stride,
#else // CONFIG_HIGHBITDEPTH
#if CONFIG_CONVOLVE_ROUND
const int is_conv_no_round = conv_params->round == CONVOLVE_OPT_NO_ROUND;
DECLARE_ALIGNED(16, CONV_BUF_TYPE, tmp_dst2[MAX_SB_SQUARE]);
int tmp_dst2_stride = MAX_SB_SIZE;
CONV_BUF_TYPE *org_dst = conv_params->dst;
int org_dst_stride = conv_params->dst_stride;
if (is_conv_no_round) {
memset(tmp_dst2, 0, sizeof(tmp_dst2));
conv_params->dst = tmp_dst2;
......
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