Skip to content
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

kind plea from visually impaired user #29

Open
JanuszChmiel opened this issue Jan 5, 2022 · 5 comments
Open

kind plea from visually impaired user #29

JanuszChmiel opened this issue Jan 5, 2022 · 5 comments

Comments

@JanuszChmiel
Copy link

Dear MR kaytat
Do you think, that there are some good Pulseaudio buffer values for Espeak speech engine, more precisely for Espeak-ng? FOrtunately, your professionally created advices on your block are still compatible. So if I run Pulseaudio on Termux but not Pulseaudio which have been prepared for Termux, but officially coded Pulseaudio for Arch Linux latest version, it is ossible to really stream sound from this server which is executed by using Termux and Proot.
But I AM facing big issues with long delay after Speech is being produced.
I AM using Orca screen reader and Speech-dispatcher speech server. The sad reality is, that Huawei have made something which causes that there is some delay after Android kernel driver will play some chunks of sound.
Even when I Am using PUlseaudio for Termux which uses Open sless. It is thanks to Huawei kernel upgrade. Version 7.0 of Android did not caused this long delay.

So I Am thinkink, if it would help if your Simple protocol player would stop to use Audio track and some advanced NDK related techniques to play audio with The lov audio latency would be used.

Thank you very much for your answer.
Reality is that your used technique is stable and do not produce issues.

@kaytat
Copy link
Owner

kaytat commented Jan 6, 2022

I have not tested this end to end with accessibility in mind and so I appreciate you bringing this to my attention.

Using something like the NDK or MediaCodec for low latency audio would require a re-write of the audio processing in the app so it's a big job. But it's something I could look at.

But I'm still unsure where the issue is. You mention a lot of Linux-specific utilities as well as Huawei/Android. I can't really tell if the issue is with the buffering on the Linux side or buffering on the Android-side.

Could you clarify that?

@JanuszChmiel
Copy link
Author

JanuszChmiel commented Jan 6, 2022 via email

@JanuszChmiel
Copy link
Author

JanuszChmiel commented Jan 6, 2022 via email

@kaytat
Copy link
Owner

kaytat commented Mar 15, 2022

I've added two new options.

  1. Performance mode low latency
    This is specific to Android O but the documentation here suggests a low latency path for output

  2. min AudioTrack buffer
    To minimize buffering, I've added a checkbox for "Min AudioTrack buffer" This option totally ignores the other buffer size option and tries to use the smallest allowable buffer size. However, this might be glitchy.

I have no yet published this to the play store.

@kaytat
Copy link
Owner

kaytat commented Mar 15, 2022

Android suggest using Oboe for low latency audio but that's going to be a bigger project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants