-
Notifications
You must be signed in to change notification settings - Fork 573
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why doesn't convertPcm16ToFloat do source[i] / 32768.0f
?
#21
Comments
Originally asked by mnaganov |
A multiply is generally much faster than a divide. It might look better to define a const float kScaleI16ToFloat = (1.0f/32768.0f) |
dturner
added a commit
that referenced
this issue
Feb 12, 2018
dturner
added a commit
that referenced
this issue
Feb 12, 2018
dturner
added a commit
that referenced
this issue
Feb 12, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This line of code (from https://github.com/google/oboe/blob/master/src/common/Utilities.cpp#L43)
destination[i] = source[i] * (1.0f / 32768.0f);
Why not just use:
source[i] / 32768.0f
The text was updated successfully, but these errors were encountered: