ref: f396c08f772a5ad4b364a9a2104b4af3678b7428
parent: 3996642cd731a1b609972ff5d4277f3a387cf12b
author: Jean-Marc Valin <[email protected]>
date: Tue Jun 17 20:52:16 EDT 2014
Adds SIG2WORD16() to fixed_debug.h
--- a/celt/fixed_debug.h
+++ b/celt/fixed_debug.h
@@ -768,6 +768,16 @@
return res;
}
+static OPUS_INLINE opus_val16 SIG2WORD16_generic(celt_sig x)
+{
+ x = PSHR32(x, SIG_SHIFT);
+ x = MAX32(x, -32768);
+ x = MIN32(x, 32767);
+ return EXTRACT16(x);
+}
+#define SIG2WORD16(x) (SIG2WORD16_generic(x))
+
+
#undef PRINT_MIPS
#define PRINT_MIPS(file) do {fprintf (file, "total complexity = %llu MIPS\n", celt_mips);} while (0);