mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-08-10 23:50:21 -04:00
Fixed ms_duration function to show actual ms (#1836)
This commit is contained in:
parent
13f12227bd
commit
f59f5dfaa3
1 changed files with 1 additions and 1 deletions
|
@ -111,7 +111,7 @@ inline uint32_t ms_duration(
|
|||
if (sample_rate == 0 || bytes_per_sample == 0)
|
||||
return 0;
|
||||
|
||||
return buffer_size / bytes_per_sample / sample_rate * 1000;
|
||||
return buffer_size * 1000 / (bytes_per_sample * sample_rate);
|
||||
}
|
||||
|
||||
int fast_int_magnitude(int y, int x);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue