mirror of
https://github.com/librespot-org/librespot.git
synced 2024-11-08 16:45:43 +00: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
|
||||
.data
|
||||
.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(),
|
||||
)));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue