We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
2022-12-28 15:09:19.155 32386-6668/com.north.arrow.technology E/CrashReport: java.lang.NullPointerException: Attempt to invoke virtual method 'int android.media.AudioRecord.read(byte[], int, int)' on a null object reference at net.ossrs.yasea.SrsPublisher$2.run(SrsPublisher.java:107) at java.lang.Thread.run(Thread.java:929) 2022-12-28 15:09:19.155 32386-6668/com.north.arrow.technology E/CrashReport: #++++++++++++++++++++++++++++++++++++++++++#
if(mic!=null){ int size = mic.read(mPcmBuffer, 0, mPcmBuffer.length); if (size > 0) { mEncoder.onGetPcmFrame(mPcmBuffer, size); } }
我对mic进行了非空判断还是出现了空指针
The text was updated successfully, but these errors were encountered:
抱歉已经不从事安卓开发了,偶尔上来看一看。你的安卓SDK还有底层驱动是官方的还是定制的?如果是定制的建议先排查一下底层问题,毕竟还没有跟您类似的问题反馈。
Sorry, something went wrong.
不是定制化的 就是平常的手机
安卓版本变化很多,也许我当时的SDK版本落后了,你可以调试一下chooseAudioRecord函数,看看是不是适合你,如果有改动,欢迎PR
chooseAudioRecord
No branches or pull requests
2022-12-28 15:09:19.155 32386-6668/com.north.arrow.technology E/CrashReport: java.lang.NullPointerException: Attempt to invoke virtual method 'int android.media.AudioRecord.read(byte[], int, int)' on a null object reference
at net.ossrs.yasea.SrsPublisher$2.run(SrsPublisher.java:107)
at java.lang.Thread.run(Thread.java:929)
2022-12-28 15:09:19.155 32386-6668/com.north.arrow.technology E/CrashReport: #++++++++++++++++++++++++++++++++++++++++++#
if(mic!=null){
int size = mic.read(mPcmBuffer, 0, mPcmBuffer.length);
if (size > 0) {
mEncoder.onGetPcmFrame(mPcmBuffer, size);
}
}
我对mic进行了非空判断还是出现了空指针
The text was updated successfully, but these errors were encountered: