Skip to content

Commit

Permalink
arch: fix inconsistent types in WORD2INT
Browse files Browse the repository at this point in the history
  • Loading branch information
tmatth committed Aug 11, 2016
1 parent e5ea11d commit bc82a53
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libspeexdsp/arch.h
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,8 @@ typedef float spx_word32_t;
#define DIV32(a,b) (((spx_word32_t)(a))/(spx_word32_t)(b))
#define PDIV32(a,b) (((spx_word32_t)(a))/(spx_word32_t)(b))

#define WORD2INT(x) ((x) < -32767.5f ? -32768 : ((x) > 32766.5f ? 32767 : floor(.5+(x))))

#define WORD2INT(x) ((x) < -32767.5f ? -32768 : \
((x) > 32766.5f ? 32767 : (spx_int16_t)floor(.5 + (x))))
#endif


Expand Down

0 comments on commit bc82a53

Please sign in to comment.