mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
audioconvert: remove S32_SCALE
We don't use it, we use S24_SCALE and then shift. Also adjust the S32_MIN and S32_MAX values, based on S24 values.
This commit is contained in:
parent
862a0746e4
commit
38b3d027ec
2 changed files with 26 additions and 16 deletions
|
|
@ -119,9 +119,8 @@
|
|||
#define F32_TO_S24_32S(v) bswap_32(F32_TO_S24_32(v))
|
||||
#define F32_TO_S24_32S_D(v,d) bswap_32(F32_TO_S24_32_D(v,d))
|
||||
|
||||
#define S32_MIN -2147483648
|
||||
#define S32_MAX 2147483647
|
||||
#define S32_SCALE 2147483648.f
|
||||
#define S32_MIN (S24_MIN * 256)
|
||||
#define S32_MAX (S24_MAX * 256)
|
||||
#define S32_TO_F32(v) ITOF(int32_t, (v) >> 8, S24_SCALE, 0.0f)
|
||||
#define S32S_TO_F32(v) S32_TO_F32(bswap_32(v))
|
||||
#define F32_TO_S32(v) (F32_TO_S24_32(v) << 8)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue