diff options
author | Stefan Pöschel <github@basicmaster.de> | 2015-05-07 20:59:21 +0200 |
---|---|---|
committer | Stefan Pöschel <github@basicmaster.de> | 2015-05-07 20:59:21 +0200 |
commit | 6e82930326b9f30fe786b5ed3dd3b74a6e751f6c (patch) | |
tree | 60ac6c5e59dafde88a8d5b151f9bfbababd3f705 /utils.h | |
parent | 76a07373d964433f4a9e22761a380fc297d726d4 (diff) | |
download | etisnoop-6e82930326b9f30fe786b5ed3dd3b74a6e751f6c.tar.gz etisnoop-6e82930326b9f30fe786b5ed3dd3b74a6e751f6c.tar.bz2 etisnoop-6e82930326b9f30fe786b5ed3dd3b74a6e751f6c.zip |
Use 960-transformation in libfaad2
Previously the (default) 1024-transformation was used for PCM output, although
DAB+ uses the 960-transformation. This lead to audio being slower and lower
than the original source.
In libfaad2 the 960-transformation can be enabled by using a carefully crafted
AudioSpecificConfig for initialization, which is carried out by this commit.
Diffstat (limited to 'utils.h')
-rw-r--r-- | utils.h | 32 |
1 files changed, 0 insertions, 32 deletions
diff --git a/utils.h b/utils.h deleted file mode 100644 index 9c43c88..0000000 --- a/utils.h +++ /dev/null @@ -1,32 +0,0 @@ -#include <stdlib.h> -#include <stdint.h> - -#ifndef __UTILS_H_ -#define __UTILS_H_ -static inline -void setBit(uint8_t x [], uint8_t bit, int32_t pos) -{ - int16_t iByte; - int16_t iBit; - - iByte = pos / 8; - iBit = pos % 8; - x[iByte] = (x[iByte] & (~(1 << (7 - iBit)))) | - (bit << (7 - iBit)); -} - -static inline -void setBits(uint8_t x[], uint32_t bits, - int32_t startPosition, int32_t numBits) -{ - int32_t i; - uint8_t bit; - - for (i = 0; i < numBits; i ++) { - bit = bits & (1 << (numBits - i - 1)) ? 1 : 0; - setBit(x, bit, startPosition + i); - } -} - -#endif - |