summaryrefslogtreecommitdiff
path: root/vp9/encoder/vp9_subexp.c
diff options
context:
space:
mode:
Diffstat (limited to 'vp9/encoder/vp9_subexp.c')
-rw-r--r--vp9/encoder/vp9_subexp.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/vp9/encoder/vp9_subexp.c b/vp9/encoder/vp9_subexp.c
index 7254a6173..799f179d9 100644
--- a/vp9/encoder/vp9_subexp.c
+++ b/vp9/encoder/vp9_subexp.c
@@ -83,35 +83,35 @@ static int prob_diff_update_cost(vpx_prob newp, vpx_prob oldp) {
return update_bits[delp] * 256;
}
-static void encode_uniform(vp9_writer *w, int v) {
+static void encode_uniform(vpx_writer *w, int v) {
const int l = 8;
const int m = (1 << l) - 191;
if (v < m) {
- vp9_write_literal(w, v, l - 1);
+ vpx_write_literal(w, v, l - 1);
} else {
- vp9_write_literal(w, m + ((v - m) >> 1), l - 1);
- vp9_write_literal(w, (v - m) & 1, 1);
+ vpx_write_literal(w, m + ((v - m) >> 1), l - 1);
+ vpx_write_literal(w, (v - m) & 1, 1);
}
}
-static INLINE int write_bit_gte(vp9_writer *w, int word, int test) {
- vp9_write_literal(w, word >= test, 1);
+static INLINE int write_bit_gte(vpx_writer *w, int word, int test) {
+ vpx_write_literal(w, word >= test, 1);
return word >= test;
}
-static void encode_term_subexp(vp9_writer *w, int word) {
+static void encode_term_subexp(vpx_writer *w, int word) {
if (!write_bit_gte(w, word, 16)) {
- vp9_write_literal(w, word, 4);
+ vpx_write_literal(w, word, 4);
} else if (!write_bit_gte(w, word, 32)) {
- vp9_write_literal(w, word - 16, 4);
+ vpx_write_literal(w, word - 16, 4);
} else if (!write_bit_gte(w, word, 64)) {
- vp9_write_literal(w, word - 32, 5);
+ vpx_write_literal(w, word - 32, 5);
} else {
encode_uniform(w, word - 64);
}
}
-void vp9_write_prob_diff_update(vp9_writer *w, vpx_prob newp, vpx_prob oldp) {
+void vp9_write_prob_diff_update(vpx_writer *w, vpx_prob newp, vpx_prob oldp) {
const int delp = remap_prob(newp, oldp);
encode_term_subexp(w, delp);
}
@@ -196,7 +196,7 @@ int vp9_prob_diff_update_savings_search_model(const unsigned int *ct,
return bestsavings;
}
-void vp9_cond_prob_diff_update(vp9_writer *w, vpx_prob *oldp,
+void vp9_cond_prob_diff_update(vpx_writer *w, vpx_prob *oldp,
const unsigned int ct[2]) {
const vpx_prob upd = DIFF_UPDATE_PROB;
vpx_prob newp = get_binary_prob(ct[0], ct[1]);
@@ -204,10 +204,10 @@ void vp9_cond_prob_diff_update(vp9_writer *w, vpx_prob *oldp,
upd);
assert(newp >= 1);
if (savings > 0) {
- vp9_write(w, 1, upd);
+ vpx_write(w, 1, upd);
vp9_write_prob_diff_update(w, newp, *oldp);
*oldp = newp;
} else {
- vp9_write(w, 0, upd);
+ vpx_write(w, 0, upd);
}
}