Commit graph

144 commits

Author SHA1 Message Date
Timothy B. Terriberry
23f503ad1c Fix warnings in pedantic build.
This should suppress our current issues with unused parameters,
 unused variables, and set-but-not-used variables.
2014-12-26 08:31:39 -08:00
xiangmingzhu
c95c9a048f Cisco optimization for x86 & fixed point
1. Only for fixed point on x86 platform (32bit and 64bit, uses SIMD
   intrinsics up to SSE4.2)
2. Use "configure --enable-fixed-point --enable-intrinsics" to enable
   optimization, default is disabled.
3. Official test cases are verified and passed.

Signed-off-by: Timothy B. Terriberry <tterribe@xiph.org>
2014-10-03 21:16:00 -04:00
Gregory Maxwell
6d2d5c424d Suppress some coverity false positives. 2014-04-16 18:29:26 -07:00
Jean-Marc Valin
ce1173c77f Fixes use of uninitialized values in dynalloc_analysis() 2014-01-20 18:46:33 -05:00
Jean-Marc Valin
379af35fd4 Minor cleanup in dynalloc_analysis() 2014-01-19 01:42:04 -05:00
Jean-Marc Valin
05548fa1c1 Adds a median filter to make dynalloc_analysis() more conservative
This should prevent extreme dynalloc behaviour in cases where some
bands are heavily attenuated.
2014-01-19 01:32:53 -05:00
Jean-Marc Valin
bdc7b93358 Reduces decoder stack usage by only storing one channel of denormalized MDCT 2014-01-06 08:58:38 -05:00
Jean-Marc Valin
4a6744a446 Some cleaning up of the synthesis code. 2014-01-05 21:40:02 -05:00
Jean-Marc Valin
e1f846208e Minor cleanup -- nothing to see here 2013-12-29 18:45:49 -05:00
Jean-Marc Valin
306d7f5a30 fixed-point: slight (but free) accuracy improvement in compute_band_energies()
Also moves the VSHR32() condition outside the loop just in case some compilers
don't optimize that properly.
2013-12-16 01:08:21 -05:00
Jean-Marc Valin
4a168eb343 Remove useless code in alloc_trim_analysis() 2013-12-11 01:34:06 -05:00
Jean-Marc Valin
91f8010108 Removing indirections 2013-12-10 22:09:33 -05:00
Pedro Becerra
a9b7def9f5 s/MAX16/MAX32/ in transient_analysis()
Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2013-12-09 16:08:29 -05:00
Jean-Marc Valin
57cd849cf7 Defining celt_inner_prod() and using it instead of explicit loops.
Also adds an SSE-optimized celt_inner_prod().
2013-12-09 15:26:58 -05:00
Jean-Marc Valin
ff072009fe Replaces inline copies and initialization with OPUS_*() macros.
This is a bit faster at -O2 because memcpy()/memmove()/memset() are
vectorized. The code is also cleaner.
2013-12-09 15:26:52 -05:00
Jean-Marc Valin
c94e4bb103 Optimizes encoder NaN detection and clipping by only running them when needed
NaN detection should now be able to catch values that would create NaNs
further down.
2013-12-09 15:26:03 -05:00
Jean-Marc Valin
5626908ec3 Fixed-point fast-path for normal 48 kHz encoding in celt_preemphasis() 2013-12-05 16:40:59 -05:00
Jean-Marc Valin
aed1009df9 Turns a 16x32 multiply into a 16x16 one in celt_preemphasis(). 2013-12-05 13:36:48 -05:00
Jean-Marc Valin
96408b6295 Fixes Opus-custom preemphasis
Also adds denorm avoidance for non-48 kHz rates
2013-12-02 20:02:37 -05:00
Jean-Marc Valin
086ea7c7e5 Whoa! This fixes a pretty bad fixed-point stereo regression 2013-11-29 16:47:52 -05:00
Jean-Marc Valin
d6eb9c468f Silences a warning in fixed-point 2013-11-25 22:33:43 -05:00
Jean-Marc Valin
2924af4db0 Merges surround and stereo intensity stereo thresholds again.
The different results for surround were mostly due to a bug in squishyball.
2013-11-25 21:24:30 -05:00
Jean-Marc Valin
a47d6f308f Intensity stereo update, partially based on Monty's listening
Intensity stereo is now based on equiv_rate and should no longer oscillate
in hybrid mode. Also, there is now a separate set of thresholds for
surround tuned by Monty. The non-surround thresholds were also updated at
low bitrate to be closer to what Monty found for surround.
2013-11-25 00:03:31 -05:00
Jean-Marc Valin
41e8906cd6 opus_custom_encoder_init() now only needed for custom modes. 2013-11-20 19:34:14 -05:00
Timothy B. Terriberry
39386e0b85 Adds Neon assembly for correlation/convolution
Optimizing celt_pitch_xcorr()/xcorr_kernel() which also speeds up
FIRs, IIRs and auto-correlations

Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2013-11-18 13:41:17 -05:00
Jean-Marc Valin
1b28e0cae5 Oops, missing semicolon on RESTORE_STACK in previous commit 2013-11-15 01:57:25 -05:00
Jean-Marc Valin
e83d2aa3f7 Adds missing RESTORE_STACKs in celt_encode_with_ec() 2013-11-15 01:52:28 -05:00
Jean-Marc Valin
2dc27dfa13 Rename preemphasis() to celt_preemphasis() to avoid amrnb symbol clash
http://lists.xiph.org/pipermail/opus/2013-November/002372.html
2013-11-13 23:18:26 -05:00
Jean-Marc Valin
ab86a9cca7 Fixes more warnings 2013-11-13 23:06:25 -05:00
Jean-Marc Valin
0d584b905a Prevents LFE from busting at really low bitrate 2013-11-13 22:42:04 -05:00
Jean-Marc Valin
a71c9adf52 Fixes MSVC conversion warnings 2013-11-13 12:07:01 -05:00
Jean-Marc Valin
ca6fac041b Fixes some minor issues found by scan build 2013-11-09 18:28:40 -05:00
Jean-Marc Valin
c1959e7dc3 Taking into account the frame size in more encoder decisions
Stereo mode, stereo width, min bandwidth, VBR damping
2013-11-08 19:24:10 -05:00
Jean-Marc Valin
8f466274d3 Removes a float var that shouldn't have been there
Defining FIXED_POINT and DISABLE_FLOAT_API now leaves no float instruction
2013-10-28 21:50:10 -04:00
Jean-Marc Valin
9c23f5cdca Makes stereo savings still less aggressive
Caps the savings at 1 bit per (coded) sample. This doesn't really increase
the bitrate and fixes some issues, e.g. with IgorC's "twilight" sample.
2013-10-28 14:15:18 -04:00
Jean-Marc Valin
942fc816d1 Replaces log2() with celt_log2() and fixes a potential divide-by-zero 2013-10-01 19:27:30 -04:00
Jean-Marc Valin
7c60625f80 Merge branch 'exp_surround1' 2013-10-01 17:06:09 -04:00
Stefan Hacker
a32fa319d3 Avoid using C++ keyword 'new'
Signed-off-by: Jean-Marc Valin <jmvalin@jmvalin.ca>
2013-09-29 00:07:52 -04:00
Jean-Marc Valin
36a21ed536 Very basic surround rate calibration 2013-09-14 15:46:09 -04:00
Jean-Marc Valin
ae7dc8a13f More surround masking tuning 2013-09-13 15:05:50 -04:00
Jean-Marc Valin
039e9ab155 Tuning the surround masking
We're now a bit more conservative and only take into account the bands
that are being codec. Also weighting the rate saving by the band width.
2013-09-12 03:05:43 -04:00
Jean-Marc Valin
ba7dbb365e Analysis scaling fixes
This should make the scaling the same for fixed and float. It changes the float
scaling too by normalizing by the number of channels, which matters for
bandwidth detection.
2013-09-09 16:39:19 -04:00
Jean-Marc Valin
3ab03e0556 First pass at making the analysis code run with FIXED_POINT
Code is still float, but at least tonality esitmation seems to work.
Speech/music analysis is still disabled.
2013-09-06 16:00:39 -04:00
Jean-Marc Valin
0f68696a97 Adds trim and dynalloc control to surround masking 2013-09-05 12:49:55 -04:00
Jean-Marc Valin
fdceae89bf Surround masking rewrite
The channel energy is now computed using an MDCT in the multi-stream
encoder rather than computing the energy of the stereo downmix.
2013-08-30 21:58:02 -04:00
Jean-Marc Valin
e45509294c Better handling of the dynalloc cap for CBR/CVBR 2013-07-30 05:12:46 -04:00
Jean-Marc Valin
8259492a7d Fixes an integer wrap-around due to an exceedingly large QCONST16 2013-07-25 13:55:15 -04:00
Gregory Maxwell
5280c71883 Revert "Fixes a number of double promotions and missing casts."
This reverts commit 43279728cd.
2013-07-15 15:51:24 -07:00
Gregory Maxwell
43279728cd Fixes a number of double promotions and missing casts.
At a minimum MSVC warns on some of this stuff.
2013-07-15 15:23:03 -07:00
Jean-Marc Valin
cd373b54de Surround masking tuning
More conservative surround masking
Disables temporal VBR on surround
Disables tonality on LFE
2013-07-07 02:51:07 -04:00