mirror of
https://github.com/librespot-org/librespot.git
synced 2025-10-03 09:49:31 +02:00
Make S16 to F32 sample conversion less magical
This commit is contained in:
parent
bfca1ec15e
commit
cdbce21e71
1 changed files with 1 additions and 1 deletions
|
@ -45,7 +45,7 @@ where
|
||||||
packet
|
packet
|
||||||
.data
|
.data
|
||||||
.iter()
|
.iter()
|
||||||
.map(|sample| ((*sample as f64 + 0.5) / (0x7FFF as f64 + 0.5)) as f32)
|
.map(|sample| ((*sample as f64 + 0.5) / (std::i16::MAX as f64 + 0.5)) as f32)
|
||||||
.collect(),
|
.collect(),
|
||||||
)));
|
)));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue