summaryrefslogtreecommitdiff
path: root/lib/rbcodec/codecs/libspeex/fixed_generic.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/rbcodec/codecs/libspeex/fixed_generic.h')
-rw-r--r--lib/rbcodec/codecs/libspeex/fixed_generic.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/rbcodec/codecs/libspeex/fixed_generic.h b/lib/rbcodec/codecs/libspeex/fixed_generic.h
index 2948177c0b..3fb096ed90 100644
--- a/lib/rbcodec/codecs/libspeex/fixed_generic.h
+++ b/lib/rbcodec/codecs/libspeex/fixed_generic.h
@@ -47,14 +47,14 @@
47#define SHR32(a,shift) ((a) >> (shift)) 47#define SHR32(a,shift) ((a) >> (shift))
48#define SHL32(a,shift) ((a) << (shift)) 48#define SHL32(a,shift) ((a) << (shift))
49#define PSHR16(a,shift) (SHR16((a)+((1<<((shift))>>1)),shift)) 49#define PSHR16(a,shift) (SHR16((a)+((1<<((shift))>>1)),shift))
50#define PSHR32(a,shift) (SHR32((a)+((1<<((shift))>>1)),shift)) 50#define PSHR32(a,shift) (SHR32((a)+((EXTEND32(1)<<((shift))>>1)),shift))
51#define VSHR32(a, shift) (((shift)>0) ? SHR32(a, shift) : SHL32(a, -(shift))) 51#define VSHR32(a, shift) (((shift)>0) ? SHR32(a, shift) : SHL32(a, -(shift)))
52#define SATURATE16(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x))) 52#define SATURATE16(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x)))
53#define SATURATE32(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x))) 53#define SATURATE32(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x)))
54 54
55#define SHR(a,shift) ((a) >> (shift)) 55#define SHR(a,shift) ((a) >> (shift))
56#define SHL(a,shift) ((spx_word32_t)(a) << (shift)) 56#define SHL(a,shift) ((spx_word32_t)(a) << (shift))
57#define PSHR(a,shift) (SHR((a)+((1<<((shift))>>1)),shift)) 57#define PSHR(a,shift) (SHR((a)+((EXTEND32(1)<<((shift))>>1)),shift))
58#define SATURATE(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x))) 58#define SATURATE(x,a) (((x)>(a) ? (a) : (x)<-(a) ? -(a) : (x)))
59 59
60 60