aboutsummaryrefslogtreecommitdiffstats
path: root/src/utils.h
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2014-04-25 09:21:35 +0200
committerMatthias P. Braendli <matthias.braendli@mpb.li>2014-04-25 09:21:35 +0200
commitca5406108cb086f57222400a08fde34686ce1b3f (patch)
tree6edbfc168ea3e2a210a1d8350ba6fcf063abaa59 /src/utils.h
parent06ac740c56bfc0aaa8b67124a09dcbf91c74cdd3 (diff)
downloadfdk-aac-dabplus-ca5406108cb086f57222400a08fde34686ce1b3f.tar.gz
fdk-aac-dabplus-ca5406108cb086f57222400a08fde34686ce1b3f.tar.bz2
fdk-aac-dabplus-ca5406108cb086f57222400a08fde34686ce1b3f.zip
dabplus-enc-file: replace little dots by nice level indicator
Diffstat (limited to 'src/utils.h')
-rw-r--r--src/utils.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/utils.h b/src/utils.h
new file mode 100644
index 0000000..c7ddc1e
--- /dev/null
+++ b/src/utils.h
@@ -0,0 +1,17 @@
+#ifndef UTILS_H_
+#define UTILS_H_
+
+#include <math.h>
+
+#define MIN(a,b) (((a)<(b))?(a):(b))
+#define MAX(a,b) (((a)>(b))?(a):(b))
+
+#define NUMOF(l) (sizeof(l) / sizeof(*l))
+
+#define linear_to_dB(x) (log10(x) * 20)
+
+
+const char* level(int channel, int* peak);
+
+#endif
+