Skip to content

Commit

Permalink
Merge pull request #66 from chenxiaolong/priority
Browse files Browse the repository at this point in the history
RecorderThread.kt: Set priority to THREAD_PRIORITY_URGENT_AUDIO
  • Loading branch information
chenxiaolong authored Jun 4, 2022
2 parents acf0117 + e82e46d commit 7ecfe36
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/src/main/java/com/chiller3/bcr/RecorderThread.kt
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ class RecorderThread(
*/
@SuppressLint("MissingPermission")
private fun recordUntilCancelled(pfd: ParcelFileDescriptor) {
AndroidProcess.setThreadPriority(AndroidProcess.THREAD_PRIORITY_AUDIO)
AndroidProcess.setThreadPriority(AndroidProcess.THREAD_PRIORITY_URGENT_AUDIO)

val audioFormat = AudioFormat.Builder().run {
setEncoding(ENCODING)
Expand Down

0 comments on commit 7ecfe36

Please sign in to comment.