opus.git
11 years agopre-emphasis coef now a constant
Jean-Marc Valin [Mon, 3 Mar 2008 06:19:17 +0000 (17:19 +1100)]
pre-emphasis coef now a constant

11 years agoA bunch of const qualifyers and a few comments
Jean-Marc Valin [Mon, 3 Mar 2008 05:52:54 +0000 (16:52 +1100)]
A bunch of const qualifyers and a few comments

11 years agoApplying the window properly in find_spectral_pitch()
Jean-Marc Valin [Mon, 3 Mar 2008 05:38:29 +0000 (16:38 +1100)]
Applying the window properly in find_spectral_pitch()

11 years agoA bit more reordering in stack memory allocation -- saved 1024 bytes on peak use
Jean-Marc Valin [Mon, 3 Mar 2008 03:53:47 +0000 (14:53 +1100)]
A bit more reordering in stack memory allocation -- saved 1024 bytes on peak use

11 years agoapplying the pitch windowing directly in find_spectral_pitch()
Jean-Marc Valin [Mon, 3 Mar 2008 03:44:42 +0000 (14:44 +1100)]
applying the pitch windowing directly in find_spectral_pitch()

11 years agoNo longer storing the zero parts of the in[] array in the encoder
Jean-Marc Valin [Mon, 3 Mar 2008 03:23:51 +0000 (14:23 +1100)]
No longer storing the zero parts of the in[] array in the encoder

11 years agoPitch predictor now uses a larger range of offset by not being limited to the
Jean-Marc Valin [Mon, 3 Mar 2008 03:08:21 +0000 (14:08 +1100)]
Pitch predictor now uses a larger range of offset by not being limited to the
window size when parts of the window are zero.

11 years agocompute_mdcts() no longer reads the part of the input that should be zeros
Jean-Marc Valin [Mon, 3 Mar 2008 02:59:55 +0000 (13:59 +1100)]
compute_mdcts() no longer reads the part of the input that should be zeros
anyway (check-point for pitch improvements to follow)

11 years agoOnly the (rising) overlap part of the window is stored now. No need to hold the
Jean-Marc Valin [Mon, 3 Mar 2008 02:49:20 +0000 (13:49 +1100)]
Only the (rising) overlap part of the window is stored now. No need to hold the
zeros and ones (nor even the second half).

11 years agoDon't bother multiplying when the window's value is one or zero
Jean-Marc Valin [Mon, 3 Mar 2008 02:24:01 +0000 (13:24 +1100)]
Don't bother multiplying when the window's value is one or zero

11 years agocwrs32-test should be 16-bit clean now.
Jean-Marc Valin [Sun, 2 Mar 2008 23:07:19 +0000 (10:07 +1100)]
cwrs32-test should be 16-bit clean now.

11 years agoLaplace encoder now works with 16-bit frequencies
Jean-Marc Valin [Sun, 2 Mar 2008 23:04:48 +0000 (10:04 +1100)]
Laplace encoder now works with 16-bit frequencies

11 years agoHadn't realised the bitr* stuff wasn't needed.
Jean-Marc Valin [Sun, 2 Mar 2008 17:11:49 +0000 (04:11 +1100)]
Hadn't realised the bitr* stuff wasn't needed.

11 years agooops, fixed the Laplace testcase
Jean-Marc Valin [Sun, 2 Mar 2008 10:25:22 +0000 (21:25 +1100)]
oops, fixed the Laplace testcase

11 years agoSaved 4 kB of stack usage in find_spectral_pitch() by doing the FFT in-place
Jean-Marc Valin [Sat, 1 Mar 2008 11:55:27 +0000 (22:55 +1100)]
Saved 4 kB of stack usage in find_spectral_pitch() by doing the FFT in-place
(sort of)

11 years agoMaking it easier to debug laplace testcase
Jean-Marc Valin [Sat, 1 Mar 2008 09:56:17 +0000 (20:56 +1100)]
Making it easier to debug laplace testcase

11 years agoStereo pitch search no longer requires twice the memory/complexity.
Jean-Marc Valin [Sat, 1 Mar 2008 09:14:20 +0000 (20:14 +1100)]
Stereo pitch search no longer requires twice the memory/complexity.

11 years agooops. Another 16-bit fix
Jean-Marc Valin [Fri, 29 Feb 2008 21:45:55 +0000 (08:45 +1100)]
oops. Another 16-bit fix

11 years ago16-bit fix
Jean-Marc Valin [Fri, 29 Feb 2008 21:33:51 +0000 (08:33 +1100)]
16-bit fix

11 years agoAnother C90-fying pass. Fixed some warnings in the process.
Jean-Marc Valin [Fri, 29 Feb 2008 20:27:03 +0000 (07:27 +1100)]
Another C90-fying pass. Fixed some warnings in the process.

11 years agoMoved mdct state and window to the mode so it can be shared between multiple
Jean-Marc Valin [Fri, 29 Feb 2008 10:08:49 +0000 (21:08 +1100)]
Moved mdct state and window to the mode so it can be shared between multiple
encoders and decoders.

11 years agoJust realised half the twiddles in the real FFT weren't even used. Removing
Jean-Marc Valin [Fri, 29 Feb 2008 09:03:41 +0000 (20:03 +1100)]
Just realised half the twiddles in the real FFT weren't even used. Removing
them saves another 1kB for fixed-point (2kB for float or full precision)

11 years agoSaved on stack usage by changing the order of the allocation
Jean-Marc Valin [Fri, 29 Feb 2008 06:24:02 +0000 (17:24 +1100)]
Saved on stack usage by changing the order of the allocation

11 years agoBit of memory reduction in the pitch search. More needed.
Jean-Marc Valin [Fri, 29 Feb 2008 06:07:53 +0000 (17:07 +1100)]
Bit of memory reduction in the pitch search. More needed.

11 years agoFixed temp arrays that were allocated too large (no change in peak mem)
Jean-Marc Valin [Fri, 29 Feb 2008 06:03:34 +0000 (17:03 +1100)]
Fixed temp arrays that were allocated too large (no change in peak mem)

11 years agofixed-point: converted intra prediction and folding, unb0rked mixed-precision
Jean-Marc Valin [Fri, 29 Feb 2008 05:40:39 +0000 (16:40 +1100)]
fixed-point: converted intra prediction and folding, unb0rked mixed-precision

11 years agofixed-point: overflow debugging now works again.
Jean-Marc Valin [Fri, 29 Feb 2008 05:07:40 +0000 (16:07 +1100)]
fixed-point: overflow debugging now works again.

11 years agoInitial support for a managed stack/scratchpad. Still needs some work.
Jean-Marc Valin [Fri, 29 Feb 2008 04:14:12 +0000 (15:14 +1100)]
Initial support for a managed stack/scratchpad. Still needs some work.

11 years agofixed-point: energy quantisation is entirely converted now.
Jean-Marc Valin [Thu, 28 Feb 2008 13:32:51 +0000 (00:32 +1100)]
fixed-point: energy quantisation is entirely converted now.

11 years agofixed-point: more energy quantisation stuff.
Jean-Marc Valin [Thu, 28 Feb 2008 13:15:10 +0000 (00:15 +1100)]
fixed-point: more energy quantisation stuff.

11 years agofixed-point: a few more bits converted from the energy quantisation. Almost done
Jean-Marc Valin [Thu, 28 Feb 2008 13:07:00 +0000 (00:07 +1100)]
fixed-point: a few more bits converted from the energy quantisation. Almost done

11 years agofixed-point: copied the exp2 implementation from Speex, using it for dB2Amp()
Jean-Marc Valin [Thu, 28 Feb 2008 12:37:26 +0000 (23:37 +1100)]
fixed-point: copied the exp2 implementation from Speex, using it for dB2Amp()

11 years agofixed-point: log approximation
Jean-Marc Valin [Thu, 28 Feb 2008 11:14:54 +0000 (22:14 +1100)]
fixed-point: log approximation

11 years agofixed-point: unquant_energy_mono() has received the fixed-point code from
Jean-Marc Valin [Thu, 28 Feb 2008 06:46:33 +0000 (17:46 +1100)]
fixed-point: unquant_energy_mono() has received the fixed-point code from
quant_energy_mono()

11 years agofixed-point: second check-point on quant_energy_mono()
Jean-Marc Valin [Thu, 28 Feb 2008 05:52:44 +0000 (16:52 +1100)]
fixed-point: second check-point on quant_energy_mono()

11 years agofixed-point: first check-point on quant_energy_mono() conversion
Jean-Marc Valin [Thu, 28 Feb 2008 05:41:56 +0000 (16:41 +1100)]
fixed-point: first check-point on quant_energy_mono() conversion

11 years agofixed-point: alg_quant() entirely converter -- may require revisiting...
Jean-Marc Valin [Thu, 28 Feb 2008 04:14:07 +0000 (15:14 +1100)]
fixed-point: alg_quant() entirely converter -- may require revisiting...

11 years agofixed-point: (hopefully) last check-point for alg_quant() conversion
Jean-Marc Valin [Thu, 28 Feb 2008 03:44:19 +0000 (14:44 +1100)]
fixed-point: (hopefully) last check-point for alg_quant() conversion

11 years agofixed-point: The cross-products in alg_quant() are now all converted.
Jean-Marc Valin [Thu, 28 Feb 2008 03:33:19 +0000 (14:33 +1100)]
fixed-point: The cross-products in alg_quant() are now all converted.

11 years agofixed-point: third alg_quant() checkpoint
Jean-Marc Valin [Thu, 28 Feb 2008 02:46:20 +0000 (13:46 +1100)]
fixed-point: third alg_quant() checkpoint

11 years agofixed-point: second check-point in the conversion of alg_quant()
Jean-Marc Valin [Thu, 28 Feb 2008 01:22:22 +0000 (12:22 +1100)]
fixed-point: second check-point in the conversion of alg_quant()

11 years agofixed-point: First check-point in alg_quant() conversion
Jean-Marc Valin [Thu, 28 Feb 2008 01:15:17 +0000 (12:15 +1100)]
fixed-point: First check-point in alg_quant() conversion

11 years agofixed-point: Added a ROUND() operator, no real change to the code
Jean-Marc Valin [Thu, 28 Feb 2008 00:33:22 +0000 (11:33 +1100)]
fixed-point: Added a ROUND() operator, no real change to the code

11 years agoOops. Fixed a missing \ in a Makefile.am
Jean-Marc Valin [Wed, 27 Feb 2008 13:28:42 +0000 (00:28 +1100)]
Oops. Fixed a missing \ in a Makefile.am

11 years agoJust in case sizeof(char)!=1
Jean-Marc Valin [Wed, 27 Feb 2008 13:14:02 +0000 (00:14 +1100)]
Just in case sizeof(char)!=1

11 years agoRemoved some unused parameters and fixed a couple -W warnings
Jean-Marc Valin [Wed, 27 Feb 2008 13:07:23 +0000 (00:07 +1100)]
Removed some unused parameters and fixed a couple -W warnings

11 years agofixed-point: Moved sqrt and cos approximations to mathops.h
Jean-Marc Valin [Wed, 27 Feb 2008 12:50:31 +0000 (23:50 +1100)]
fixed-point: Moved sqrt and cos approximations to mathops.h

11 years agofixed-point: done with mix_pitch_and_residual() though a bit of cleaning up
Jean-Marc Valin [Wed, 27 Feb 2008 06:46:49 +0000 (17:46 +1100)]
fixed-point: done with mix_pitch_and_residual() though a bit of cleaning up
wouldn't hurt

11 years agofixed-point: mix_pitch_and_residual() check-point #3
Jean-Marc Valin [Wed, 27 Feb 2008 06:23:04 +0000 (17:23 +1100)]
fixed-point: mix_pitch_and_residual() check-point #3

11 years agofixed-point: another mix_pitch_and_residual() check-point
Jean-Marc Valin [Wed, 27 Feb 2008 06:05:43 +0000 (17:05 +1100)]
fixed-point: another mix_pitch_and_residual() check-point

11 years agofixed-point: half-way converting mix_pitch_and_residual() -- just check-pointing
Jean-Marc Valin [Wed, 27 Feb 2008 05:52:30 +0000 (16:52 +1100)]
fixed-point: half-way converting mix_pitch_and_residual() -- just check-pointing

11 years agofixed-point: compression factor (alpha) now a 16-bit value (still internally
Jean-Marc Valin [Wed, 27 Feb 2008 05:17:39 +0000 (16:17 +1100)]
fixed-point: compression factor (alpha) now a 16-bit value (still internally
converted to float though)

11 years agofixed-point: converted pitch_quant_bands() -- that one was an easy one-liner
Jean-Marc Valin [Wed, 27 Feb 2008 04:44:18 +0000 (15:44 +1100)]
fixed-point: converted pitch_quant_bands() -- that one was an easy one-liner

11 years agofixed-point: converted compute_pitch_gain() and removed the energy-based
Jean-Marc Valin [Wed, 27 Feb 2008 04:35:43 +0000 (15:35 +1100)]
fixed-point: converted compute_pitch_gain() and removed the energy-based
weighting that didn't seem to help anyway.

11 years agoFixing pi again before another massive public outcry
Jean-Marc Valin [Wed, 27 Feb 2008 03:07:45 +0000 (14:07 +1100)]
Fixing pi again before another massive public outcry

11 years agofixed-point: exp_rotation() mostly converted (still need to convert the cos/sin)
Jean-Marc Valin [Wed, 27 Feb 2008 02:49:54 +0000 (13:49 +1100)]
fixed-point: exp_rotation() mostly converted (still need to convert the cos/sin)

11 years agofixed-point: no float vars left (and nearly no float ops left) in celt.c
Jean-Marc Valin [Wed, 27 Feb 2008 01:09:50 +0000 (12:09 +1100)]
fixed-point: no float vars left (and nearly no float ops left) in celt.c

11 years agofixed-point: log-energy for previous frame now a 16-bit value. This currently
Jean-Marc Valin [Wed, 27 Feb 2008 00:59:05 +0000 (11:59 +1100)]
fixed-point: log-energy for previous frame now a 16-bit value. This currently
intruduces a bit of an encoder-decoder mismatch (Q8 in dB), but it'll be
reduced when the interals of quant_energy_mono() are properly converted to
fixed-point and oldEBands gets rounded instead of truncated.

11 years agofixed-point: converted window to 16-bit value
Jean-Marc Valin [Wed, 27 Feb 2008 00:25:25 +0000 (11:25 +1100)]
fixed-point: converted window to 16-bit value

11 years agofixed-point: pre/de-emphasis converted.
Jean-Marc Valin [Wed, 27 Feb 2008 00:08:53 +0000 (11:08 +1100)]
fixed-point: pre/de-emphasis converted.

11 years agoReduced code duplication in vq.c by adding mix_pitch_and_residual() which
Jean-Marc Valin [Tue, 26 Feb 2008 23:09:48 +0000 (10:09 +1100)]
Reduced code duplication in vq.c by adding mix_pitch_and_residual() which
is used by both by the encoding and decoding functions.

11 years agoC90-fying ectest
Jean-Marc Valin [Tue, 26 Feb 2008 20:48:48 +0000 (07:48 +1100)]
C90-fying ectest

11 years agoAnother 16-bit fix.
Jean-Marc Valin [Tue, 26 Feb 2008 12:59:54 +0000 (23:59 +1100)]
Another 16-bit fix.

11 years agofixed-point: got stereo to work again by fixing renormalise_bands()
Jean-Marc Valin [Tue, 26 Feb 2008 09:32:24 +0000 (20:32 +1100)]
fixed-point: got stereo to work again by fixing renormalise_bands()

11 years agofixed-point: celt_pgain_t now a 16-bit value (Q15)
Jean-Marc Valin [Tue, 26 Feb 2008 06:02:08 +0000 (17:02 +1100)]
fixed-point: celt_pgain_t now a 16-bit value (Q15)

11 years agocelt_mask_t for masking curves
Jean-Marc Valin [Tue, 26 Feb 2008 05:43:04 +0000 (16:43 +1100)]
celt_mask_t for masking curves

11 years agoRemoved useless masking curve for current frame and ignored Fs argument to
Jean-Marc Valin [Tue, 26 Feb 2008 05:35:19 +0000 (16:35 +1100)]
Removed useless masking curve for current frame and ignored Fs argument to
masking computation functions.

11 years agopitch gain is now celt_pgain_t
Jean-Marc Valin [Tue, 26 Feb 2008 05:19:03 +0000 (16:19 +1100)]
pitch gain is now celt_pgain_t

11 years agofixed-point: band energy now a 32-bit value. It might have (barely) fix into
Jean-Marc Valin [Tue, 26 Feb 2008 04:41:51 +0000 (15:41 +1100)]
fixed-point: band energy now a 32-bit value. It might have (barely) fix into
16-bit, but at this point, it's not worth the trouble and loss of accuracy.

11 years agofixed-point: added a celt_ener_t type for band energy.
Jean-Marc Valin [Tue, 26 Feb 2008 03:46:26 +0000 (14:46 +1100)]
fixed-point: added a celt_ener_t type for band energy.

11 years agoMinus a bunch of warnings when enabling alloca()
Jean-Marc Valin [Tue, 26 Feb 2008 02:51:53 +0000 (13:51 +1100)]
Minus a bunch of warnings when enabling alloca()

11 years agoPut the channel count outside of the energy calculation. Increased the allowed
Jean-Marc Valin [Tue, 26 Feb 2008 02:48:16 +0000 (13:48 +1100)]
Put the channel count outside of the energy calculation. Increased the allowed
range for the mono encoder.

11 years agofixed-point: celt_norm_t now a 16-bit value.
Jean-Marc Valin [Tue, 26 Feb 2008 00:38:00 +0000 (11:38 +1100)]
fixed-point: celt_norm_t now a 16-bit value.

11 years ago16-bit fixes and warning fixes
Jean-Marc Valin [Mon, 25 Feb 2008 23:38:17 +0000 (10:38 +1100)]
16-bit fixes and warning fixes

11 years agoTrying to be nice with 16-bit chips.
Jean-Marc Valin [Mon, 25 Feb 2008 23:28:20 +0000 (10:28 +1100)]
Trying to be nice with 16-bit chips.

11 years agoCorrected the last digit of pi after massive public outcry :-)
Jean-Marc Valin [Mon, 25 Feb 2008 20:38:27 +0000 (07:38 +1100)]
Corrected the last digit of pi after massive public outcry :-)

11 years agoOgg decoder does gapless for the beginning of the file.
Jean-Marc Valin [Mon, 25 Feb 2008 06:58:21 +0000 (17:58 +1100)]
Ogg decoder does gapless for the beginning of the file.

11 years agofixed-point: Using a NORM_SCALING of 16384, sig_norm_t is still a float though.
Jean-Marc Valin [Mon, 25 Feb 2008 06:41:30 +0000 (17:41 +1100)]
fixed-point: Using a NORM_SCALING of 16384, sig_norm_t is still a float though.

11 years agofixed-point: celt_sig_t now a 32-bit value.
Jean-Marc Valin [Mon, 25 Feb 2008 03:55:09 +0000 (14:55 +1100)]
fixed-point: celt_sig_t now a 32-bit value.

11 years agofixed-point: initial support for using the fixed-point MDCT (rest is still all
Jean-Marc Valin [Mon, 25 Feb 2008 03:05:10 +0000 (14:05 +1100)]
fixed-point: initial support for using the fixed-point MDCT (rest is still all
float)

11 years agoMDCT is in fixed-point now
Jean-Marc Valin [Mon, 25 Feb 2008 01:07:13 +0000 (12:07 +1100)]
MDCT is in fixed-point now

11 years agoMDCT conversion, part I.
Jean-Marc Valin [Mon, 25 Feb 2008 00:49:38 +0000 (11:49 +1100)]
MDCT conversion, part I.

11 years agoreal fft no longer needs an internal buffer.
Jean-Marc Valin [Sun, 24 Feb 2008 22:47:25 +0000 (09:47 +1100)]
real fft no longer needs an internal buffer.

11 years agoreal fft snr comparison testcase includes DC
Jean-Marc Valin [Sun, 24 Feb 2008 12:48:15 +0000 (23:48 +1100)]
real fft snr comparison testcase includes DC

11 years agoFloat FFT now does the same scaling as the fixed-point FFT
Jean-Marc Valin [Sun, 24 Feb 2008 11:36:05 +0000 (22:36 +1100)]
Float FFT now does the same scaling as the fixed-point FFT

11 years agominor tweak to FFT
Jean-Marc Valin [Sun, 24 Feb 2008 11:06:04 +0000 (22:06 +1100)]
minor tweak to FFT

11 years agoAdded a mixed-precision version of the FFT with 32-bit data and 16-bit twiddles.
Jean-Marc Valin [Sun, 24 Feb 2008 06:16:47 +0000 (17:16 +1100)]
Added a mixed-precision version of the FFT with 32-bit data and 16-bit twiddles.

11 years agoCreated an separate kiss_twiddle_cpx type to make it possible to use
Jean-Marc Valin [Sun, 24 Feb 2008 02:46:30 +0000 (13:46 +1100)]
Created an separate kiss_twiddle_cpx type to make it possible to use
different precision for twiddles and data.

11 years agoMDCT now scales down by N/2 instead of N/4. The factor two is moved to the
Jean-Marc Valin [Fri, 22 Feb 2008 10:45:16 +0000 (21:45 +1100)]
MDCT now scales down by N/2 instead of N/4. The factor two is moved to the
overlap-add during synthesis.

11 years agotestcase for the MDCT and IMDCT
Jean-Marc Valin [Fri, 22 Feb 2008 07:02:56 +0000 (18:02 +1100)]
testcase for the MDCT and IMDCT

11 years agoIncreased precision for real FFT
Jean-Marc Valin [Fri, 22 Feb 2008 06:34:13 +0000 (17:34 +1100)]
Increased precision for real FFT

11 years agoOops, forgot a file
Jean-Marc Valin [Fri, 22 Feb 2008 05:30:33 +0000 (16:30 +1100)]
Oops, forgot a file

11 years agoFixed the FFT for higher precision
Jean-Marc Valin [Fri, 22 Feb 2008 05:19:39 +0000 (16:19 +1100)]
Fixed the FFT for higher precision

11 years agoAdding celt_sig_t where needed
Jean-Marc Valin [Fri, 22 Feb 2008 03:45:58 +0000 (14:45 +1100)]
Adding celt_sig_t where needed

11 years agoSeparating types for normalised vs. denormalised data paths
Jean-Marc Valin [Fri, 22 Feb 2008 03:24:50 +0000 (14:24 +1100)]
Separating types for normalised vs. denormalised data paths

11 years agoFixed the real fft testsuite as well
Jean-Marc Valin [Fri, 22 Feb 2008 02:20:05 +0000 (13:20 +1100)]
Fixed the real fft testsuite as well

11 years agoFixed stuff that got broken during the forward-backward split of the FFT
Jean-Marc Valin [Fri, 22 Feb 2008 01:13:59 +0000 (12:13 +1100)]
Fixed stuff that got broken during the forward-backward split of the FFT

11 years agoAdded a TODO list
Jean-Marc Valin [Fri, 22 Feb 2008 00:24:45 +0000 (11:24 +1100)]
Added a TODO list

11 years agoMaking sure freed or corrupted modes can't be used (produce a run-time warning).
Jean-Marc Valin [Thu, 21 Feb 2008 13:39:25 +0000 (00:39 +1100)]
Making sure freed or corrupted modes can't be used (produce a run-time warning).

11 years agoUpdated the header and celtenc/celtdec tools to the new way modes are handled.
Jean-Marc Valin [Thu, 21 Feb 2008 12:59:17 +0000 (23:59 +1100)]
Updated the header and celtenc/celtdec tools to the new way modes are handled.