summaryrefslogtreecommitdiff
path: root/libavcodec/opus_silk.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2022-10-03 22:47:58 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2022-10-05 02:15:43 +0200
commitc095358289559d91932bd2ea48f90848ecee1f80 (patch)
treec36a638e81c8f2caaa6579263e4b47e73ad0c524 /libavcodec/opus_silk.c
parent81b927a53bafd51b3874ae7c36c6948cc632c267 (diff)
avcodec/opus: Move defines to better places
Move ROUND_MUL* macros to their only users and the Celt macros to opus_celt.h. Also improve the other headers a bit while at it. Reviewed-by: Lynne <dev@lynne.ee> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavcodec/opus_silk.c')
-rw-r--r--libavcodec/opus_silk.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/opus_silk.c b/libavcodec/opus_silk.c
index f9d67f4fb3..fd1e83659c 100644
--- a/libavcodec/opus_silk.c
+++ b/libavcodec/opus_silk.c
@@ -26,9 +26,12 @@
#include <stdint.h>
+#include "mathops.h"
#include "opus.h"
#include "opustab.h"
+#define ROUND_MULL(a,b,s) (((MUL64(a, b) >> ((s) - 1)) + 1) >> 1)
+
typedef struct SilkFrame {
int coded;
int log_gain;