Giter Site home page Giter Site logo

Comments (9)

madhavajay avatar madhavajay commented on June 30, 2024

Mine crashes too, seems like it runs out of memory???
Device is Nexus 4 with Android 5.0.1

04-12 18:14:10.876 6643-6643/com.example.android.camera2video I/art﹕ Late-enabling -Xcheck:jni
04-12 18:14:11.067 6643-6671/com.example.android.camera2video D/OpenGLRenderer﹕ Render dirty regions requested: true
04-12 18:14:11.074 6643-6643/com.example.android.camera2video D/Atlas﹕ Validating map...
04-12 18:14:11.144 6643-6671/com.example.android.camera2video I/Adreno-EGL﹕ <qeglDrvAPI_eglInitialize:410>: QUALCOMM Build: 10/28/14, c33033c, Ia6306ec328
04-12 18:14:11.146 6643-6671/com.example.android.camera2video I/OpenGLRenderer﹕ Initialized EGL, version 1.4
04-12 18:14:11.169 6643-6671/com.example.android.camera2video D/OpenGLRenderer﹕ Enabling debug mode 0
04-12 18:14:11.218 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value normal
04-12 18:14:11.219 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value emboss
04-12 18:14:11.219 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value sketch
04-12 18:14:11.219 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value neon
04-12 18:14:11.222 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value asd
04-12 18:14:11.222 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value backlight
04-12 18:14:11.222 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value flowers
04-12 18:14:11.222 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value AR
04-12 18:14:11.233 6643-6643/com.example.android.camera2video E/Camera2VideoFragment﹕ Couldn't find any suitable preview size
04-12 18:14:11.240 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value normal
04-12 18:14:11.241 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value emboss
04-12 18:14:11.241 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value sketch
04-12 18:14:11.241 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value neon
04-12 18:14:11.241 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value asd
04-12 18:14:11.241 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value backlight
04-12 18:14:11.241 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value flowers
04-12 18:14:11.241 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value AR
04-12 18:14:11.247 6643-6643/com.example.android.camera2video I/CameraManager﹕ Using legacy camera HAL.
04-12 18:14:11.498 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value normal
04-12 18:14:11.498 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value emboss
04-12 18:14:11.498 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value sketch
04-12 18:14:11.499 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value neon
04-12 18:14:11.499 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value asd
04-12 18:14:11.499 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value backlight
04-12 18:14:11.499 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value flowers
04-12 18:14:11.499 6643-6643/com.example.android.camera2video W/ArrayUtils﹕ Ignoring invalid value AR
04-12 18:14:11.632 6643-6643/com.example.android.camera2video I/CameraDeviceState﹕ Legacy camera service transitioning to state CONFIGURING
04-12 18:14:11.633 6643-6693/com.example.android.camera2video I/RequestThread-0﹕ Configure outputs: 2 surfaces configured.
04-12 18:14:11.633 6643-6693/com.example.android.camera2video D/Camera﹕ app passed NULL surface
04-12 18:14:11.667 6643-6643/com.example.android.camera2video I/CameraDeviceState﹕ Legacy camera service transitioning to state IDLE
04-12 18:14:11.675 6643-6670/com.example.android.camera2video I/RequestQueue﹕ Repeating capture request set.
04-12 18:14:11.681 6643-6693/com.example.android.camera2video W/LegacyRequestMapper﹕ convertRequestMetadata - control.awbRegions setting is not supported, ignoring value
04-12 18:14:11.681 6643-6693/com.example.android.camera2video W/LegacyRequestMapper﹕ Only received metering rectangles with weight 0.
04-12 18:14:11.681 6643-6693/com.example.android.camera2video W/LegacyRequestMapper﹕ Only received metering rectangles with weight 0.
04-12 18:14:12.092 6643-6707/com.example.android.camera2video I/CameraDeviceState﹕ Legacy camera service transitioning to state CAPTURING
04-12 18:14:17.519 6643-6707/com.example.android.camera2video W/Adreno-EGLSUB﹕ DequeueBuffer:721: dequeue native buffer fail: No such device, buffer=0x0, handle=0x0
04-12 18:14:17.519 6643-6707/com.example.android.camera2video W/Adreno-ES20﹕ <core_glFlush:52>: GL_OUT_OF_MEMORY
04-12 18:14:17.523 6643-6707/com.example.android.camera2video W/GLConsumer﹕ [unnamed-6643-1] bindTextureImage: clearing GL error: 0x505
04-12 18:14:17.528 6643-6707/com.example.android.camera2video W/Adreno-EGLSUB﹕ DequeueBuffer:721: dequeue native buffer fail: No such device, buffer=0x0, handle=0x0
04-12 18:14:17.528 6643-6707/com.example.android.camera2video W/Adreno-ES20﹕ <core_glFlushInternal:37>: GL_OUT_OF_MEMORY
04-12 18:14:17.532 6643-6707/com.example.android.camera2video E/CameraDeviceGLThread-0﹕ Received exception on GL render thread:
java.lang.IllegalStateException: onDrawFrame start: GLES20 error: 0x505
at android.hardware.camera2.legacy.SurfaceTextureRenderer.checkGlError(SurfaceTextureRenderer.java:494)
at android.hardware.camera2.legacy.SurfaceTextureRenderer.drawFrame(SurfaceTextureRenderer.java:213)
at android.hardware.camera2.legacy.SurfaceTextureRenderer.drawIntoSurfaces(SurfaceTextureRenderer.java:680)
at android.hardware.camera2.legacy.GLThreadManager$1.handleMessage(GLThreadManager.java:103)
at android.os.Handler.dispatchMessage(Handler.java:98)
at android.os.Looper.loop(Looper.java:135)
at android.os.HandlerThread.run(HandlerThread.java:61)
04-12 18:14:17.532 6643-6707/com.example.android.camera2video I/CameraDeviceState﹕ Legacy camera service transitioning to state ERROR
04-12 18:14:17.875 6643-6643/com.example.android.camera2video W/System.err﹕ android.hardware.camera2.CameraAccessException: The camera device has encountered a serious error
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.hardware.camera2.impl.CameraDeviceImpl.checkIfCameraClosedOrInError(CameraDeviceImpl.java:1478)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.hardware.camera2.impl.CameraDeviceImpl.createCaptureRequest(CameraDeviceImpl.java:476)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at com.example.android.camera2video.Camera2VideoFragment.startPreview(Camera2VideoFragment.java:408)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at com.example.android.camera2video.Camera2VideoFragment.stopRecordingVideo(Camera2VideoFragment.java:543)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at com.example.android.camera2video.Camera2VideoFragment.onClick(Camera2VideoFragment.java:292)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.view.View.performClick(View.java:4756)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.view.View$PerformClick.run(View.java:19749)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.os.Handler.handleCallback(Handler.java:739)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.os.Handler.dispatchMessage(Handler.java:95)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.os.Looper.loop(Looper.java:135)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at android.app.ActivityThread.main(ActivityThread.java:5221)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at java.lang.reflect.Method.invoke(Native Method)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at java.lang.reflect.Method.invoke(Method.java:372)
04-12 18:14:17.879 6643-6643/com.example.android.camera2video W/System.err﹕ at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:899)
04-12 18:14:17.880 6643-6643/com.example.android.camera2video W/System.err﹕ at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:694)
04-12 18:14:20.526 6643-6693/com.example.android.camera2video E/RequestThread-0﹕ Timed out while waiting for request to complete.
04-12 18:14:20.554 6643-6693/com.example.android.camera2video W/CaptureCollector﹕ Preview buffers dropped for request: 0
04-12 18:14:20.554 6643-6693/com.example.android.camera2video E/CameraDeviceState﹕ Cannot receive result while in state: 0
04-12 18:14:20.555 6643-6693/com.example.android.camera2video E/CameraDeviceState﹕ Cannot receive result while in state: 0
04-12 18:14:20.593 6643-6693/com.example.android.camera2video E/CameraDeviceState﹕ Cannot receive result while in state: 0
04-12 18:14:20.620 6643-6660/com.example.android.camera2video W/MessageQueue﹕ Handler (android.graphics.SurfaceTexture$1) {1582ed32} sending message to a Handler on a dead thread
java.lang.IllegalStateException: Handler (android.graphics.SurfaceTexture$1) {1582ed32} sending message to a Handler on a dead thread
at android.os.MessageQueue.enqueueMessage(MessageQueue.java:325)
at android.os.Handler.enqueueMessage(Handler.java:631)
at android.os.Handler.sendMessageAtTime(Handler.java:600)
at android.os.Handler.sendMessageDelayed(Handler.java:570)
at android.os.Handler.sendEmptyMessageDelayed(Handler.java:534)
at android.os.Handler.sendEmptyMessage(Handler.java:519)
at android.graphics.SurfaceTexture.postEventFromNative(SurfaceTexture.java:368)
04-12 18:14:20.644 6643-6693/com.example.android.camera2video E/BufferQueueProducer﹕ [unnamed-6643-1] cancelBuffer: BufferQueue has been abandoned
04-12 18:14:20.648 6643-6693/com.example.android.camera2video E/BufferQueueProducer﹕ [unnamed-6643-1] cancelBuffer: BufferQueue has been abandoned
04-12 18:14:20.652 6643-6693/com.example.android.camera2video E/BufferQueueProducer﹕ [unnamed-6643-1] cancelBuffer: BufferQueue has been abandoned
04-12 18:14:20.655 6643-6693/com.example.android.camera2video E/BufferQueueProducer﹕ [unnamed-6643-1] cancelBuffer: BufferQueue has been abandoned
04-12 18:14:20.659 6643-6693/com.example.android.camera2video E/BufferQueueProducer﹕ [unnamed-6643-1] cancelBuffer: BufferQueue has been abandoned
04-12 18:14:20.798 6643-6643/com.example.android.camera2video I/Choreographer﹕ Skipped 174 frames! The application may be doing too much work on its main thread.

from android-camera2video.

hantc avatar hantc commented on June 30, 2024

Same here, Nexus 4, Android 5.1

from android-camera2video.

madhavajay avatar madhavajay commented on June 30, 2024

Hey Hantc, check my PR:
#6

Its based on a fix from someone over on the Xamarin port.
Works for me on the Nexus 4 on 5.1 :)

from android-camera2video.

hantc avatar hantc commented on June 30, 2024

Many thanks! Works. I tried to fix it by myself (according to xamarin fix),
but as I'm new in this technology so I wasn't able to:)

2015-04-24 8:57 GMT+02:00 madhavajay [email protected]:

Hey Hantc, check my PR:
#6 #6

Its based on a fix from someone over on the Xamarin port.
Works for me on the Nexus 4 on 5.1 :)


Reply to this email directly or view it on GitHub
#5 (comment)
.

from android-camera2video.

madhavajay avatar madhavajay commented on June 30, 2024

No problems! :) Good luck.

from android-camera2video.

xyz1hang avatar xyz1hang commented on June 30, 2024

I think the description of the stop() method does mean something. Perhaps the reason it crashes is that no valid audio/video data received, which is also why there's empty output file ? Do you not get empty output file ? @madhavajay

Stops recording. Call this after start(). Once recording is stopped,
     * you will have to configure it again as if it has just been constructed.
     * Note that a RuntimeException is intentionally thrown to the
     * application, if no valid audio/video data has been received when stop()
     * is called. This happens if stop() is called immediately after
     * start(). The failure lets the application take action accordingly to
     * clean up the output file (delete the output file, for instance), since
     * the output file is not properly constructed when this happens.
     *
     * @throws IllegalStateException if it is called before start()

from android-camera2video.

 avatar commented on June 30, 2024

check out this stackoverflow answer
worked for me

from android-camera2video.

prudhvirajkumar10 avatar prudhvirajkumar10 commented on June 30, 2024

For those who are getting SurfaceAbandonedException just remove the mMediaRecorder.stop() / mMediaRecorder.release(); from the stopRecordingVideo() method. The mediaplayer causes the surface to destroy and leading to app crash

from android-camera2video.

codingjeremy avatar codingjeremy commented on June 30, 2024

This sample has been migrated to a new location where we can accept Pull Requests (check README for more information).

As recommended by GitHub, we are closing all issues and pull requests now that this older repo will be archived.

If you still see this issue in the updated repo, please reopen the issue/PR there. Thank you!

from android-camera2video.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.