android - Phone freezes when camera.release() is called -
hi i'm trying camera functionality work on app. problem is, on 1 phone in particular - samsung galaxy mini.
after take picture using camera , previews, phone freezes when call camera.release(). have remove battery reset it.
this how release camera:
try { mcamera.stoppreview(); mcamera.setpreviewdisplay(null); mcamera.release(); mcamera = null; } catch (exception e) { // ignore: tried stop non-existent preview }
i getting weird native exception in logcat after call:
03-10 09:45:56.080: e/mm-camera(95): camera_issue_ctrl_cmd: error (bad address): type 43, length 0, status 40856
any appreciated!
use below open source camera code you
and use on surface destroyed
if(flag){ camera.release(); camera = null; previewing = false; }else{ camera.stoppreview(); }
Comments
Post a Comment