Gregory Maxwell
40f956eed0
Various minor cleanups (removing dead arguments, macros) to libcelt/. Reinstate -Wunused-parameter.
2011-09-01 19:42:37 -04:00
Gregory Maxwell
d6335abedc
Adds many syntactically unnecessary parentheses to silence GCC -Wparentheses.
...
The object code is unchanged (except ectest). Also reenables -Wparentheses, -Wsign-compare,
and the MSVC warnings.
2011-08-30 20:16:23 -04:00
Gregory Maxwell
75d27803d5
Adds many syntactically unnecessary parentheses to silence MSVC C4554.
...
The object code is unchanged.
2011-08-30 14:08:25 -04:00
Jean-Marc Valin
be89c39587
Using OPUS_ macros for <string.h> operations
...
Removes a bunch of system #include <...> in the process
2011-08-30 12:39:51 -04:00
Benjamin M. Schwartz
711eade6d5
Reduce the number of branches around ncwrs* and ucwrs* calls with k==0.
...
This slightly reduces the executable size and might improve
performance on platforms without good branch prediction.
2011-08-17 15:58:34 -04:00
Jean-Marc Valin
1c6c3d17a7
Removes unused functions from cwrs.c
2011-08-15 09:43:52 -04:00
Gregory Maxwell
f9b1b3fec8
Shrink INV_TABLE to save a little memory.
2011-08-12 13:20:26 -04:00
Gregory Maxwell
da752d1883
Eliminate some unreachable cases from the cwrs code and fixup the
...
asserts to reflect the actual limits. Update the cwrs test to cover
the complete n,k range used by opus/opus_custom.
2011-08-12 13:08:13 -04:00
Jean-Marc Valin
f334c82ec3
Adds a fuzzing mode that causes the encoder to make random decisions
2011-08-11 16:48:05 -04:00
Gregory Maxwell
662587d9c5
Remove many unused defines and convert some double constants to float.
2011-08-01 20:41:54 -04:00
Gregory Maxwell
71d39ad841
Correct many whitespace errors under libcelt/ and remove
...
non-ascii characters from the source.
2011-07-30 21:54:59 -04:00
Jean-Marc Valin
d77d6a58fc
Renamed celt_[u]int* to opus_[u]int*
2011-07-29 17:33:06 -04:00
Timothy B. Terriberry
9bac8c17d5
Eliminate the ec_int32 and ec_uint32 typedefs.
...
These were used because the entropy coder originally came from
outside libcelt, and thus did not have a common type system.
It's now undergone enough modification that it's not ever likely to
be used as-is in another codec without some porting effort, so
there's no real reason to maintain the typedefs separately.
Hopefully we'll replace these all again somedate with a common set
of Opus typedefs, but for now this will do.
This fixes an issue caused by commit 6c8acbf1
, which moved the
ec_ilog() prototype from entcode.h to ecintrin.h, where the
ec_uint32 typedef was not yet available.
Thanks to John Ridges for the report.
2011-03-02 21:14:19 -05:00
Jean-Marc Valin
3806c1d738
Relicensing under the simplified (2-clause) BSD license
...
Got authorization from all copyright holders
2011-02-09 22:37:41 -05:00
Jean-Marc Valin
5ad35bf3bf
Enabling the standard static mode by default
2011-01-28 22:42:09 -05:00
Jean-Marc Valin
3fc0aada01
FFT cleanup
2010-08-25 17:15:05 -04:00
Jean-Marc Valin
732ea38810
Updated static modes for new pulse cache.
...
Fixed a few minor bugs in the process.
2010-08-25 13:52:27 -04:00
Jean-Marc Valin
3ad8db49c5
New pulse cache
2010-08-25 13:11:09 -04:00
Timothy B. Terriberry
68242ac58c
Eliminate the loop when decoding the split angle.
...
Use a closed-form formula for the search instead.
This requires an integer sqrt, so it is not actually closed-form,
but the number of iterations is O(qb) instead of O(2**qb).
2010-07-28 00:20:16 +02:00
Jean-Marc Valin
2fcb239736
Removing the rest of the >32-bit PVQ code
2010-05-24 09:05:36 -04:00
Jean-Marc Valin
cae30df09a
Getting rid of PVQ-level split
...
Adding one more level of band splitting so that splitting at the
PVQ encoding level is no longer necessary.
2010-05-21 00:26:03 -04:00
Jean-Marc Valin
811f21ab76
Fix for very short frame size (M=1)
2010-05-07 21:20:22 -04:00
Jean-Marc Valin
9319e3e6df
Removing original freq-domain pitch code
2009-11-09 13:51:54 +09:00
Jean-Marc Valin
630ee44aaa
SMALL_FOOTPRINT preserves the special n=1 cwrs case
2009-10-24 14:29:15 -04:00
Jean-Marc Valin
c2f7dff55a
Added a SMALL_FOOTPRINT option
2009-10-24 11:44:07 -04:00
Jean-Marc Valin
8b2ff0da5a
Updated copyright notices
2009-10-17 21:40:10 -04:00
Jean-Marc Valin
30f7f813ea
Changed all the celt*int*_t types to remove the _t suffix, which is reserved
...
by POSIX. The other _t types that are not part of the API are still there
for now. Also, got rid of all that was left of the 64-bit types.
2009-10-17 14:35:13 -04:00
Timothy B. Terriberry
6391fe8229
Minor optimisation -- using do-while() instead of for() in isqrt32()
2009-05-26 23:15:05 -04:00
Gregory Maxwell
8eadcdc611
Switch the N=5 case of CWRS to also use a binary search.
...
This avoids the need for 64-bit addition and is faster on x86_64.
It may be slower on some platforms so the direct solution is still
available in the source.
2009-05-26 19:17:48 -04:00
Timothy B. Terriberry
d98d8ae087
CWRS clean-ups and optimizations.
...
Adds specialized O(N*log(K)) versions of cwrsi() and O(N) versions of icwrs()
for N={3,4,5}, which allows them to operate all the way up to the theoretical
pulse limit without serious performance degredation.
Also substantially reduces the computation time and stack usage of
get_required_bits().
On x86-64, this gives a 2% speed-up for 256 sample frames, and almost a 16%
speed-up for 64 sample frames.
2009-05-26 19:07:41 -04:00
Jean-Marc Valin
381d05aa0b
Make it possible to use more than 255 pulses (not used yet).
2009-05-19 10:12:34 -04:00
Timothy B. Terriberry
747378a43b
Fix (unexploitable) buffer overrun when _m=1 during the cwrs table init, as
...
reported by Bjoern Rasmussen.
2009-04-11 22:21:06 -04:00
Gregory Maxwell
122c98920f
Minor enhancements to celtenc to avoid silently capping bitrate and allow an
...
adjustable frame size. Indentation fix in cwrs.c.
2009-02-03 18:22:50 -05:00
Timothy B. Terriberry
2036c57b8a
Ensure that log2_frac() is _really_ an upper bound.
...
This version has actually been tested for all 32-bit inputs.
2008-12-17 07:31:44 -05:00
Timothy B. Terriberry
c7ace558fe
Fix log2_frac() to return an upper bound, not a lower bound.
2008-12-17 07:31:38 -05:00
Timothy B. Terriberry
310fb3cb4d
Compute the real maximum required bits for a split.
2008-12-17 07:31:08 -05:00
Jean-Marc Valin
5a3d49eb11
Fixes two bugs in get_required_bits() for the split cwrs case.
2008-12-07 14:39:42 -05:00
Jean-Marc Valin
f3190f26b9
s/unsigned/celt_uint32_t/
2008-10-01 19:41:54 -04:00
Jean-Marc Valin
b155bb8860
Merge branch 'cwrs_speedup'
...
Conflicts:
libcelt/cwrs.c
tests/cwrs32-test.c
2008-09-21 22:38:43 -04:00
Timothy B.B Terriberry
5ee9715c5c
Change cwrsi() to operate on rows of U instead of columns.
...
It is no slower with a large number of pulses, and as much as 30% faster with
a large number of dimensions.
2008-09-21 21:37:41 -04:00
Jean-Marc Valin
abf5c8ed64
Merge branch 'cwrs_speedup' (derf's cwrs changes)
...
Conflicts:
libcelt/cwrs.c
2008-09-19 08:02:50 -04:00
Timothy B.B Terriberry
d910274f79
Change CWRS indexing to use Pyramid VQ's magnitude ordering.
...
This lets us encode and decode directly from the pulse vector without an
intermediate transformation.
This makes old streams undecodable.
Additionally, ncwrs_u32() has been sped up for large N by using the sliding
recurrence from Mohorko et al.
ncwrs_u64 could be sped up in a similar manner, but would require a larger
table of multiplicative inverses (or several 32x32->64 bit multiplies).
Note that U(N,M) is now everywhere 1/2 the value it used to be.
2008-09-19 07:38:24 -04:00
Jean-Marc Valin
b781877e80
Converted everything to 32-bit CWRS (using split after that)
2008-09-12 21:27:35 -04:00
Jean-Marc Valin
453ccd829a
Generate slightly more accurate WMOPS figures
2008-09-12 20:52:27 -04:00
Jean-Marc Valin
9eba823cf7
Turns out that the worse case of the vector split is the same as that of the
...
pulse split. Also, added an allocation line for even higher bit-rates
2008-08-02 20:51:44 -04:00
Jean-Marc Valin
b0c153b15d
Doing the cwrs split in dimensions should save a few bits.
2008-06-11 18:05:57 +10:00
Jean-Marc Valin
f892d5f68e
Turns out maxK and maxM were also inverted in fits_in64()
2008-06-10 23:46:12 +10:00
Jean-Marc Valin
51891c9d5c
fixed a cwrs bug in fits_in32()
2008-06-10 20:57:52 +10:00
Jean-Marc Valin
679083f449
Implemented split-cwrs for very large codebooks (>64 bits), but still getting
...
a few decoding errors.
2008-06-10 17:23:03 +10:00
Jean-Marc Valin
5aff7c04d4
Implemented a cleaner way to detect whether CWRS codebooks fit in 32 or 64 bits
2008-06-10 16:25:45 +10:00