Commit fcc7edd4 authored by Alex Converse's avatar Alex Converse Committed by Gerrit Code Review
Browse files

Merge "Fix some ans const warnings." into nextgenv2

parents bf692e85 6e14846c
......@@ -151,14 +151,14 @@ static void cost(int *costs, vpx_tree tree, const vpx_prob *probs,
#if CONFIG_ANS
void vp10_cost_tokens_ans(int *costs, const vpx_prob *tree_probs,
const rans_dec_lut *token_cdf, int skip_eob) {
const rans_dec_lut token_cdf, int skip_eob) {
int c_tree = 0; // Cost of the "tree" nodes EOB and ZERO.
int i;
costs[EOB_TOKEN] = vp10_cost_bit(tree_probs[0], 0);
if (!skip_eob)
c_tree = vp10_cost_bit(tree_probs[0], 1);
for (i = ZERO_TOKEN; i <= CATEGORY6_TOKEN; ++i) {
const int p = (*token_cdf)[i + 1] - (*token_cdf)[i];
const int p = token_cdf[i + 1] - token_cdf[i];
costs[i] = c_tree + vp10_prob_cost10[p];
}
}
......
......@@ -57,7 +57,7 @@ void vp10_cost_tokens_skip(int *costs, const vpx_prob *probs, vpx_tree tree);
#if CONFIG_ANS
void vp10_cost_tokens_ans(int *costs, const vpx_prob *tree_probs,
const rans_dec_lut *token_cdf, int skip_eob);
const rans_dec_lut token_cdf, int skip_eob);
#endif
#ifdef __cplusplus
......
......@@ -167,9 +167,9 @@ void vp10_fill_token_costs(vp10_coeff_cost *c,
#if CONFIG_ANS
const vpx_prob *const tree_probs = p[t][i][j][k][l];
vp10_cost_tokens_ans((int *)c[t][i][j][k][0][l], tree_probs,
&cdf[t][i][j][k][l], 0);
cdf[t][i][j][k][l], 0);
vp10_cost_tokens_ans((int *)c[t][i][j][k][1][l], tree_probs,
&cdf[t][i][j][k][l], 1);
cdf[t][i][j][k][l], 1);
#else
vpx_prob probs[ENTROPY_NODES];
vp10_model_to_full_probs(p[t][i][j][k][l], probs);
......
......@@ -469,7 +469,7 @@ static void tokenize_b(int plane, int block, int blk_row, int blk_col,
cpi->common.fc->coef_probs[tx_size][type][ref];
#endif // CONFIG_ENTROPY
#if CONFIG_ANS
rans_dec_lut(*const coef_cdfs)[COEFF_CONTEXTS] =
rans_dec_lut (*const coef_cdfs)[COEFF_CONTEXTS] =
cpi->common.fc->coef_cdfs[tx_size][type][ref];
#endif // CONFIG_ANS
unsigned int (*const eob_branch)[COEFF_CONTEXTS] =
......@@ -493,7 +493,7 @@ static void tokenize_b(int plane, int block, int blk_row, int blk_col,
add_token(&t, coef_probs[band[c]][pt],
#if CONFIG_ANS
&coef_cdfs[band[c]][pt],
(const rans_dec_lut*)&coef_cdfs[band[c]][pt],
#endif // CONFIG_ANS
extra, (uint8_t)token, (uint8_t)skip_eob, counts[band[c]][pt]);
......
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