Further simplified the API by passing the rate directly to the
encode function. Also, trying to properly flush the bit packer
(still some problems left).
diff --git a/libcelt/vq.c b/libcelt/vq.c
index e380900..c632946 100644
--- a/libcelt/vq.c
+++ b/libcelt/vq.c
@@ -187,7 +187,7 @@
// printf ("%d ", iy[0][i]);
pulse2comb(N, K, comb, signs, iy[0]);
ec_enc_uint64(enc,icwrs64(N, K, comb, signs),ncwrs64(N, K));
-
+ //printf ("%llu ", icwrs64(N, K, comb, signs));
/* Recompute the gain in one pass to reduce the encoder-decoder mismatch
due to the recursive computation used in quantisation */
if (1) {
@@ -232,6 +232,7 @@
float g;
id = ec_dec_uint64(dec, ncwrs64(N, K));
+ //printf ("%llu ", id);
cwrsi64(N, K, id, comb, signs);
comb2pulse(N, K, iy, comb, signs);
//for (i=0;i<N;i++)