mirror of
https://github.com/librespot-org/librespot.git
synced 2024-12-18 17:11:53 +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
|
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…
Reference in a new issue