ref: f9fdbffb72d953b6a386d066f6b1c6de4be90a87
parent: 9e72ae21283f819698d1ffa852fbfe2c6f4116fa
author: Jean-Marc Valin <[email protected]>
date: Sun Sep 5 17:02:38 EDT 2010
Don't allow transients for 2.5 ms frames. It never made sense anyway.
--- a/configure.ac
+++ b/configure.ac
@@ -5,8 +5,8 @@
AM_CONFIG_HEADER([config.h])
CELT_MAJOR_VERSION=0
-CELT_MINOR_VERSION=8
-CELT_MICRO_VERSION=1
+CELT_MINOR_VERSION=9
+CELT_MICRO_VERSION=0
CELT_EXTRA_VERSION=
CELT_VERSION=$CELT_MAJOR_VERSION.$CELT_MINOR_VERSION.$CELT_MICRO_VERSION$CELT_EXTRA_VERSION
LIBCELT_SUFFIX=0
@@ -118,7 +118,7 @@
fi])
float_approx=$has_float_approx
-AC_ARG_ENABLE(float-approx, [ --disable-float-approx do not use fast approximations for floating point],
+AC_ARG_ENABLE(float-approx, [ --enable-float-approx enable fast approximations for floating point],
[ if test "$enableval" = yes; then
AC_WARN([Floating point approximations are not supported on all platforms.])
float_approx=yes
--- a/libcelt/celt.c
+++ b/libcelt/celt.c
@@ -629,7 +629,7 @@
resynth = optional_resynthesis!=NULL;
- if (st->complexity > 1)
+ if (st->complexity > 1 && LM>0)
{
isTransient = M > 1 &&
transient_analysis(in, N+st->overlap, C, &transient_time,
@@ -746,7 +746,8 @@
error, enc, C, LM, nbAvailableBytes, st->force_intra,
&st->delayedIntra, st->complexity >= 4);
- ec_enc_bit_prob(enc, shortBlocks!=0, 8192);
+ if (LM > 0)
+ ec_enc_bit_prob(enc, shortBlocks!=0, 8192);
if (shortBlocks)
{
@@ -1488,7 +1489,10 @@
unquant_coarse_energy(st->mode, st->start, st->end, bandE, oldBandE,
intra_ener, st->mode->prob, dec, C, LM);
- isTransient = ec_dec_bit_prob(dec, 8192);
+ if (LM > 0)
+ isTransient = ec_dec_bit_prob(dec, 8192);
+ else
+ isTransient = 0;
if (isTransient)
shortBlocks = M;
--- a/libcelt/modes.h
+++ b/libcelt/modes.h
@@ -43,7 +43,7 @@
#define MAX_CONFIG_SIZES 5
-#define CELT_BITSTREAM_VERSION 0x8000000d
+#define CELT_BITSTREAM_VERSION 0x8000000e
#ifdef STATIC_MODES
#include "static_modes.h"