Repository navigation
refractor: Native audio handling. The big big audio rework - #132
Merged
Merged
Conversation
Added info for Android 13+ users
Major changes, some mixed since I didn't commit along. I still need to fix the FakeContext, scrcpy does a bit more for some phone so I need to do that, more extensive testing and then release v2
Tested the code on lower android version, it now has been tested on AOSP emulator Android 11,13,15,16. Some changes where made due to some mistakes, improvements and comments update too.
Tried to configure verification-metadata.xml again but even without the scrcpy binary it is complex. There are a lot of possible failure cases which make me consider if it's worth the big hassle. At least caching should be improved. I think.
Related to a user debug build test #130 (comment)
Forgot to clean strings during the refractor... Also added voice recognition and remote submix as debug.
Declare audiorecord as non private since normal calling app does not have priviledges to bypass that check, so they probably get silenced by the OS. Also a couple of new audio sources. May need to refractor the reflection AudioRecord because it bugged me a bit when I got to edit it.
Fun fact, I just learned that c# out parameter is possible between C+ and Java. C+ equivalent to c# is to declare int *sessionId in its signatures . For C+ -- Java communication, they make uses of arrays since the object stays the same, but the content inside can change across processes.
Quickly checked the changelogs while trying to make the PR
This was
linked to
issues
Oct 20, 2026
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Big refractor related to audio handling, scrcpy is gone, couple of unrelated edits since I kind of worked on this over 2 month as a "test" to see if I could figure it out and didn't do any commit at the start. There is also one related change for a bug fix.
Tested by myself on a couple of Android version via emulator. Others used tested debug builds and confirmed it worked.
Closes #1, #13, #73, #130, #49, #114