infinum / Android-GoldenEye

A wrapper for Camera1 and Camera2 API which exposes simple to use interface.
Apache License 2.0
376 stars 53 forks source link

Regarding Video Capture #32

Closed bhavesh-srashtasoft closed 5 years ago

bhavesh-srashtasoft commented 5 years ago

Hiii,

I am getting error in library when i capturing image when i capture first video that will shoot completed. in after that i am getting exception surface can not be null.

domagojkorman commented 5 years ago

Hi,

I need more information to fix the issue. Can you please provide steps how to reproduce the issue and on which device the issue happened (device name and Android version)? It would be awesome if you could also send stacktrace.

bhavesh-srashtasoft commented 5 years ago

OK When i will record a video first time i will recording completly fine and playing but when i am record video again then it will not playing properly

Getting Error Here

private fun initMediaRecorder(file: File) { if (activity.hasAudioPermission().not()) { LogDelegate.log("Recording video without audio. Missing RECORDAUDIO permission.") } mediaRecorder = MediaRecorder().buildCamera2Instance(activity, config, file).apply { setOnErrorListener { , , -> callback?.onError(MediaRecorderDeadException) } } }

override fun createSession(textureView: TextureView) { initTextureViewSurface(textureView) initMediaRecorder(file!!) /*

You can check video from this link

Video To check issue Click here to see video

and getting issue in all devices

bhavesh-srashtasoft commented 5 years ago

Hiii anyone here can help me?

domagojkorman commented 5 years ago

I need to look into the issue to see what is wrong. Thanks for detailed report.

In the meantime. Can you try forcing Camera1 API and see whether it works OK there?

Here is how you can do it - https://github.com/infinum/Android-GoldenEye#manually-set-camera-api

bhavesh-srashtasoft commented 5 years ago

OK Let me try this

bhavesh-srashtasoft commented 5 years ago

Gettting same error video is not recording

bhavesh-srashtasoft commented 5 years ago

Hii @domagojkorman is there can you found any solutions?

domagojkorman commented 5 years ago

Can you please provide stacktrace so I can debug and look into the issue? I did not manage to reproduce it myself.

bhavesh-srashtasoft commented 5 years ago

In a log i am getting only exception Which i already sent you and also sent you where is exception generate i also given you

domagojkorman commented 5 years ago

You did not send a stacktrace. You simply copy/pasted the code where the issue is happening.

I need a stacktrace so I can see the flow which caused the issue.

EDIT: Do you receive the same error in example app when you try to record video multiple times?

domagojkorman commented 5 years ago

Closing as I could not reproduce the issue and the report was incomplete.