-
-
Notifications
You must be signed in to change notification settings - Fork 932
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
MediaRecorder: start failed: -2147483648 on specific devices #148
Comments
@natario1 thx for this project, by the way do you have any idea on this ? |
No, no idea, maybe the file you are passing to startRecording is invalid. Which File are you passing? |
hi @natario1, i have testing across many devices, ur library works fine on most device except htc and huawei. End up i use another library that implement camera 2 api. |
i have same error. |
I got same issue run in emulator |
Hoping this was solved by #264 , feel free to reopen. |
I also found the same error on the CUBOT_X18_Plus device
Then I do this
and solved it, Alhamdulillah.. |
If you are trying to report a bug, please file the information below.
Prerequisites:
Detailed steps to reproduce the issue:
Expected behavior:
able to record video
Actual behavior:
not able to record video
Screenshots:
Interesting logs:
01-22 08:51:43.534 10317-10338/com.otaliastudios.cameraview.demo E/MediaRecorder: start failed: -2147483648
01-22 08:51:43.535 10317-10338/com.otaliastudios.cameraview.demo E/Camera1: Error while starting MediaRecorder. Swallowing. java.lang.RuntimeException: start failed.
java.lang.RuntimeException: start failed.
at android.media.MediaRecorder.start(Native Method)
at com.otaliastudios.cameraview.Camera1$14.run(Camera1.java:604)
at com.otaliastudios.cameraview.Camera1$2.run(Camera1.java:58)
at android.os.Handler.handleCallback(Handler.java:751)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:154)
at android.os.HandlerThread.run(HandlerThread.java:61)
01-22 08:51:43.537 10317-10338/com.otaliastudios.cameraview.demo I/Camera1: endVideoImmediately: is capturing: true
01-22 08:51:43.537 10317-10338/com.otaliastudios.cameraview.demo E/MediaRecorder: stop called in an invalid state: 0
01-22 08:51:43.538 10317-10338/com.otaliastudios.cameraview.demo W/Camera1: endVideoImmediately: Error while closing media recorder. Swallowing java.lang.IllegalStateException
java.lang.IllegalStateException
at android.media.MediaRecorder.stop(Native Method)
at com.otaliastudios.cameraview.Camera1.endVideoImmediately(Camera1.java:634)
at com.otaliastudios.cameraview.Camera1.access$1500(Camera1.java:24)
at com.otaliastudios.cameraview.Camera1$14.run(Camera1.java:609)
at com.otaliastudios.cameraview.Camera1$2.run(Camera1.java:58)
at android.os.Handler.handleCallback(Handler.java:751)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:154)
at android.os.HandlerThread.run(HandlerThread.java:61)
You can use
CameraLogger.setLogLevel(LEVEL_VERBOSE)
to add logs to logcat, and
CameraLogger.registerLogger()
to handle logs yourself (e.g. export to file or a crash reporting service)
so you can collect data from your users.
The text was updated successfully, but these errors were encountered: