aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/opus_celt.h
diff options
context:
space:
mode:
authorRostislav Pehlivanov <atomnuker@gmail.com>2017-09-23 00:38:37 +0100
committerRostislav Pehlivanov <atomnuker@gmail.com>2017-09-23 08:27:44 +0100
commit2ad1768c7b48b6c77bbe9c42a4c2744f7b029182 (patch)
treecf97ad8da31d2e5695b4135f88ae92b90fe2f053 /libavcodec/opus_celt.h
parent1ef7752d64cbe9af2f27cc65aba3a2ca3831c128 (diff)
downloadffmpeg-2ad1768c7b48b6c77bbe9c42a4c2744f7b029182.tar.gz
opusenc: implement a psychoacoustic system
This commit implements a psychoacoustic system for the native Opus encoder. Its unlike any other psychoacoustic system known since its capable of using a lookahead to make better choices on how to treat the current frame and how many bits to allocate for it (and future frames). Also, whilst the main bulk of the analysis function has to run in a single thread, the per-frame anaylsis functions does not modify the main psychoacoustic context, so in the future it will be fairly trivial to run those as slice threads. Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
Diffstat (limited to 'libavcodec/opus_celt.h')
-rw-r--r--libavcodec/opus_celt.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/libavcodec/opus_celt.h b/libavcodec/opus_celt.h
index 31299912bd..45d50ab27b 100644
--- a/libavcodec/opus_celt.h
+++ b/libavcodec/opus_celt.h
@@ -120,6 +120,12 @@ struct CeltFrame {
uint32_t seed;
enum CeltSpread spread;
+ /* Encoder PF coeffs */
+ int pf_octave;
+ int pf_period;
+ int pf_tapset;
+ float pf_gain;
+
/* Bit allocation */
int framebits;
int remaining;