#include "aom_dsp/dkboolreader.h"
#endif
#include "aom_dsp/prob.h"
+#include "av1/common/odintrin.h"
#ifdef __cplusplus
extern "C" {
#endif
}
+static INLINE int aom_read_tree_cdf(aom_reader *r, const uint16_t *cdf,
+ int nsymbs) {
+#if CONFIG_DAALA_EC
+ return daala_read_tree_cdf(r, cdf, nsymbs);
+#else
+ (void)r;
+ (void)cdf;
+ (void)nsymbs;
+ assert(0 && "Unsupported bitreader operation");
+ return -1;
+#endif
+}
+
#ifdef __cplusplus
} // extern "C"
#endif
#endif
}
+static INLINE void aom_write_tree_cdf(aom_writer *w, int symb,
+ const uint16_t *cdf, int nsymbs) {
+#if CONFIG_DAALA_EC
+ daala_write_tree_cdf(w, symb, cdf, nsymbs);
+#else
+ (void)w;
+ (void)symb;
+ (void)cdf;
+ (void)nsymbs;
+ assert(0 && "Unsupported bitwriter operation");
+#endif
+}
+
#ifdef __cplusplus
} // extern "C"
#endif
return -i;
}
+static INLINE int daala_read_tree_cdf(daala_reader *r, const uint16_t *cdf,
+ int nsymbs) {
+ return od_ec_decode_cdf_q15(&r->ec, cdf, nsymbs, "aom");
+}
+
#ifdef __cplusplus
} // extern "C"
#endif
} while (len);
}
+static INLINE void daala_write_tree_cdf(daala_writer *w, int symb,
+ const uint16_t *cdf, int nsymbs) {
+ od_ec_encode_cdf_q15(&w->ec, symb, cdf, nsymbs);
+}
+
#ifdef __cplusplus
} // extern "C"
#endif