-
Notifications
You must be signed in to change notification settings - Fork 582
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
Huawei P30: AAudio a sound is corrupted and OpenSL has a high latency #952
Comments
Some Huawei devices do not support mono recording properly. Try recording in stereo and then just use the first channel. Some Huawei devices disable the FAST mixer so they will have higher than expected latency for OpenSL ES. We can try to workaround the mono input issue. Can you please tell me what you get for these properties?
|
Thank you very much for the reply. I will try to use stereo mic. - will tell you tomorrow. Regarding the properties:
|
I have tried to use 2 channels for the input stream as you suggested before. For Huawei P30 it still does not work, on other phones it works fine. Is there anything else I can do? |
The mono recording problem was fixed in Q for Mate 20 and possibly for P30 as well. They both use the Kirin 980.
So this may be a different issue. It may be related to the CPU performance. @banburubi - Is there any improvement if you tap on the screen while running? That can boost the CPU frequencies on some devices. Does LiveEffect have the same problem on the P30? Have you tried the "ECHO INPUT to OUTPUT" test in OboeTester? To find more information about the device you can run this ADB script on Linux or Mac.
|
Hey, update from my side. I've tested it on also on Huawei P Smart 2019, with default Android 9.0. It has the same issue with the sound corruption.
Thank you very much. |
User has solved their problem. |
Android version(s): 10 (10.1.0.123 (C431E22R2P5))
Android device(s): Huawei P30 (ELE-L29)
Oboe version: 1.4.2
App name used for testing: Similar to LiveEffect
Short description
Steps to reproduce
In voice related application, I'm working on, I'm having some issues on Huawei P30 related to how AAudio and OpenSL behave. On other tested phones of different vendors it works without any issues.
The application has almost the same setup as LiveEffect. There are 2 streams: one for input and another for output, both a requested in Exclusive, Low-latency, I16 mode. Input stream has 1 channel, Output stream has 2 channels. Callback is attached to the output stream. Sample rate and frames per callback are set using this method: https://github.com/google/oboe/blob/master/docs/GettingStarted.md#obtaining-optimal-latency
After requesting streams I'm getting such parameters:
========
AAudio:
Output:
Input:
========
OpenSL:
Output:
Input:
========
Expected behavior
On Huawei P30: With AAudio the sound is not corrupted. With OpenSL the latency is low.
Actual behavior
On Huawei P30: With AAudio the sound is corrupted. With OpenSL the latency is high.
Looking forward to your feedback.
Thank you very much.
P.S. Probably these issues are related:
#525
#386
Best,
Vladymyr.
The text was updated successfully, but these errors were encountered: