申请突然关闭

时间:2019-04-11 10:58:07

标签: java android

我正在开发一个应用程序,其中我使用play-services-vision版本17.0.2扫描qrcode。.我正在运行android oreo 8.1.0的Galaxy S5上对其进行测试。一旦我的代码到达CameraSource.start(holder)行,应用程序将关闭,而不会发出任何警告。谁能帮我吗?

ps .:我没有在其他设备上尝试过,仅在模拟器上尝试过,但是相机在那儿无法正常工作。

ps2 .:所有权限都在运行时给出,但也在清单中

给出
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.READ_PHONE_STATE"/>
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.VIBRATE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.hardware.camera" />
<uses-permission android:name="android.hardware.camera.autofocus" />

代码

Display display = getWindowManager().getDefaultDisplay();
Point size = new Point();
display.getSize(size);
_surfacce = (SurfaceView)findViewById(R.id.surfaceView);
_detector = new BarcodeDetector.Builder(getApplicationContext())
                               .setBarcodeFormats(Barcode.QR_CODE)
                               .build();
_camera=new CameraSource.Builder(getApplicationContext(),_detector)
                        .setRequestedFps(15.0f)
                        .setAutoFocusEnabled(true)
                        .setRequestedPreviewSize(size.x,size.y)
                        .setFacing(CameraSource.CAMERA_FACING_BACK)
                        .build();
_surfacce.getHolder().addCallback(new SurfaceHolder.Callback() {
    @Override
    public void surfaceCreated(SurfaceHolder holder) {
        if(ContextCompat.checkSelfPermission(getApplicationContext(),Manifest.permission.CAMERA)!= PackageManager.PERMISSION_GRANTED){
            getParent().finish();
            return;
        }
        try {
            _camera.start(_surfacce.getHolder()); //<<<< CRASHES HERE
        } catch (Exception e) {
            Log.e("CAMERA SOURCE", e.getMessage());
        }
    }
}

Logcat:

2019-04-11 15:34:02.882 347-347/? I/mm-camera: mct_controller_new: __DBG__ session_idx=2
2019-04-11 15:34:02.882 347-347/? E/mm-camera-sensor: module_sensor_start_session:1186 session 2
2019-04-11 15:34:02.894 347-347/? E/mm-camera: companion_open:1432 Enter
2019-04-11 15:34:02.895 347-347/? E/mm-camera-sensor: companion_thread_create:320 E
2019-04-11 15:34:02.896 347-32191/? E/mm-camera-sensor: companion_thread_func:187 Start.
2019-04-11 15:34:02.898 347-32191/? E/mm-camera-sensor: companion_thread_func:209 companion_thread entering the polling loop...
2019-04-11 15:34:02.899 347-347/? E/mm-camera: companion_open:1505 companion thread created.
2019-04-11 15:34:02.899 347-347/? E/mm-camera: companion_open:1508 Exit
2019-04-11 15:34:02.899 347-347/? E/mm-camera-sensor: sensor_load_library:91 s5k2p2xx : load from phone
2019-04-11 15:34:02.903 347-347/? E/mm-camera: companion_config_interface:1631 Secondary sd name /dev/v4l-subdev16
2019-04-11 15:34:02.903 347-347/? E/mm-camera: companion_config_interface:1638 i2c node open passed
2019-04-11 15:34:02.903 347-347/? E/mm-camera-sensor: module_sensor_init_session:844 sensor position 0
2019-04-11 15:34:02.903 347-347/? E/mm-camera-sensor: eeprom_set_bytestream:1608 Enter
2019-04-11 15:34:02.903 347-347/? E/mm-camera-sensor: eeprom_set_bytestream:1619 Exit
2019-04-11 15:34:02.904 347-347/? E/mm-camera-sensor: sensor_init:514 subdev name v4l-subdev19
2019-04-11 15:34:02.936 347-347/? E/mm-camera-sensor: module_sensor_init_session:932 Sending companion load fw message
2019-04-11 15:34:02.936 347-347/? E/mm-camera: companion_process:2114 Sending COMPANION_THREAD_MSG_FW_LOAD msg to companion thread !
2019-04-11 15:34:02.936 347-347/? E/mm-camera: companion_post_msg_to_thread:497 msg.type=1
2019-04-11 15:34:02.936 347-32191/? E/mm-camera-sensor: companion_thread_process_pipe_message:277 COMPANION_THREAD_MSG_FW_LOAD: loading firmware from companion thread
2019-04-11 15:34:02.937 347-32191/? E/mm-camera: companion_process:2133 Start load firmware !
2019-04-11 15:34:02.937 347-32191/? E/mm-camera: companion_load_firmware_a:1011 [E]
2019-04-11 15:34:02.937 347-347/? E/mm-camera-sensor: sensor_write_init_settings:364 Start write sensor init setting
2019-04-11 15:34:02.937 347-347/? E/mm-camera-sensor: sensor_write_init_settings:367 Sensor name : s5k2p2xx
2019-04-11 15:34:02.937 347-347/? E/mm-camera-sensor: sensor_write_init_settings:369 2p2 sensor rev check
2019-04-11 15:34:02.943 347-347/? E/mm-camera-sensor: sensor_write_init_settings:383 Sensor rev : 0xc7
2019-04-11 15:34:02.944 347-347/? E/mm-camera-sensor: sensor_write_init_settings:404 write sensor init data
2019-04-11 15:34:02.944 347-347/? E/mm-camera-sensor: sensor_write_init_settings:443 2p2 EVT2_4 sensor
2019-04-11 15:34:02.948 347-32191/? E/mm-camera: companion_load_firmware_b:1033 [E]
2019-04-11 15:34:02.948 347-32191/? E/mm-camera: companion_load_firmware_b:1035 Loading firmware
2019-04-11 15:34:02.952 13648-13648/com.android.systemui E/FalsingLog: isFalseTouch Session did not become active after query for a false touch. enabled=0/0 mScreenOn=1/1 mState=KGRD/KGRD. Look for warnings ~1000ms earlier to see root cause.; Log written to /data/user_de/0/com.android.systemui/falsing-2019-04-11-16-34-02.txt
    java.lang.Throwable: here
        at com.android.systemui.classifier.FalsingManager.isFalseTouch(FalsingManager.java:205)
        at com.android.systemui.statusbar.phone.KeyguardAffordanceHelper.flingWithCurrentVelocity(KeyguardAffordanceHelper.java:323)
        at com.android.systemui.statusbar.phone.KeyguardAffordanceHelper.endMotion(KeyguardAffordanceHelper.java:218)
        at com.android.systemui.statusbar.phone.KeyguardAffordanceHelper.onTouchEvent(KeyguardAffordanceHelper.java:180)
        at com.android.systemui.statusbar.phone.NotificationPanelView.onTouchEvent(NotificationPanelView.java:1030)
        at android.view.View.dispatchTouchEvent(View.java:11796)
        at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2962)
        at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2643)
        at android.view.ViewGroup.dispatchTransformedTouchEvent(ViewGroup.java:2968)
        at android.view.ViewGroup.dispatchTouchEvent(ViewGroup.java:2657)
        at com.android.systemui.statusbar.phone.StatusBarWindowView.dispatchTouchEvent(StatusBarWindowView.java:332)
        at android.view.View.dispatchPointerEvent(View.java:12035)
        at android.view.ViewRootImpl$ViewPostImeInputStage.processPointerEvent(ViewRootImpl.java:4795)
        at android.view.ViewRootImpl$ViewPostImeInputStage.onProcess(ViewRootImpl.java:4609)
        at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4147)
        at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4200)
        at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4166)
        at android.view.ViewRootImpl$AsyncInputStage.forward(ViewRootImpl.java:4293)
        at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4174)
        at android.view.ViewRootImpl$AsyncInputStage.apply(ViewRootImpl.java:4350)
        at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4147)
        at android.view.ViewRootImpl$InputStage.onDeliverToNext(ViewRootImpl.java:4200)
        at android.view.ViewRootImpl$InputStage.forward(ViewRootImpl.java:4166)
        at android.view.ViewRootImpl$InputStage.apply(ViewRootImpl.java:4174)
        at android.view.ViewRootImpl$InputStage.deliver(ViewRootImpl.java:4147)
        at android.view.ViewRootImpl.deliverInputEvent(ViewRootImpl.java:6661)
        at android.view.ViewRootImpl.doProcessInputEvents(ViewRootImpl.java:6635)
        at android.view.ViewRootImpl.enqueueInputEvent(ViewRootImpl.java:6596)
        at android.view.ViewRootImpl$WindowInputEventReceiver.onInputEvent(ViewRootImpl.java:6764)
        at android.view.InputEventReceiver.dispatchInputEvent(InputEventReceiver.java:186)
        at android.os.MessageQueue.nativePollOnce(Native Method)
        at android.os.MessageQueue.next(MessageQueue.java:325)
        at android.os.Looper.loop(Looper.java:142)
        at android.app.ActivityThread.main(ActivityThread.java:6494)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:440)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807)
2019-04-11 15:34:02.965 507-546/system_process W/BroadcastQueue: Background execution not allowed: receiving Intent { act=android.intent.action.DROPBOX_ENTRY_ADDED flg=0x10 (has extras) } to com.google.android.gms/.stats.service.DropBoxEntryAddedReceiver
2019-04-11 15:34:02.965 507-546/system_process W/BroadcastQueue: Background execution not allowed: receiving Intent { act=android.intent.action.DROPBOX_ENTRY_ADDED flg=0x10 (has extras) } to com.google.android.gms/.chimera.GmsIntentOperationService$PersistentTrustedReceiver
2019-04-11 15:34:02.982 347-32191/? E/mm-camera: companion_load_firmware_c:1057 [E]
2019-04-11 15:34:03.022 347-32191/? E/mm-camera: companion_cal_data_write:1079 Calibration data write
2019-04-11 15:34:03.040 347-347/? E/mm-camera-sensor: sensor_write_init_settings:493 End write sensor init setting
2019-04-11 15:34:03.040 347-347/? E/mm-camera-sensor: eeprom_process:1750 EEPROM_GET_ACTUATOR_NAME: ak7345
2019-04-11 15:34:03.040 347-347/? E/mm-camera-sensor: af_actuator_init:334 name = ak7345
2019-04-11 15:34:03.040 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:477 s_bundle->eeprom_data: 0xacec1480
2019-04-11 15:34:03.040 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2007 hw info F16QL
2019-04-11 15:34:03.040 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2031 3A Name = F16QL_libTsAe.so
2019-04-11 15:34:03.040 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2037 3a name (type : 0) F16QL_libTsAe.so
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:496 AEC lib : load from phone : F16QL_libTsAe.so
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:502 aec 0xab23d52d
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2007 hw info F16QL
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2031 3A Name = F16QL_libTs_J_Awb.so
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2037 3a name (type : 2) F16QL_libTs_J_Awb.so
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:521 AWB lib : load from phone : F16QL_libTs_J_Awb.so
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:527 awb 0x6075139
2019-04-11 15:34:03.042 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2007 hw info F16QL
2019-04-11 15:34:03.043 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2031 3A Name = F16QL_libTs_J_Accm.so
2019-04-11 15:34:03.043 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2037 3a name (type : 3) F16QL_libTs_J_Accm.so
2019-04-11 15:34:03.043 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:546 ACCM lib : load from phone : F16QL_libTs_J_Accm.so
2019-04-11 15:34:03.043 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:552 accm 0xd34946e3
2019-04-11 15:34:03.043 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2007 hw info F16QL
2019-04-11 15:34:03.043 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2031 3A Name = F16QL_libTsAf.so
2019-04-11 15:34:03.043 347-347/? E/mm-camera-sensor: [mm]hwinfo_make_3a_name:2037 3a name (type : 1) F16QL_libTsAf.so
2019-04-11 15:34:03.046 13648-13648/com.android.systemui D/StatusBar: disable<e i a s b h r c s q >
2019-04-11 15:34:03.051 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:571 AF lib : load from phone : F16QL_libTsAf.so
2019-04-11 15:34:03.051 347-347/? E/mm-camera-sensor: module_sensor_load_3a_libs:577 af 0x45b4312d
2019-04-11 15:34:03.051 347-347/? E/camera-llv: llv_init, E
2019-04-11 15:34:03.053 347-347/? E/mm-camera: stats_module_start_session: E, kur sessionid=2, module=0xacf30520
2019-04-11 15:34:03.053 347-347/? E/mm-camera: aec_module_start_session E kur module 0xacf305e0 sessionid=131072
2019-04-11 15:34:03.054 347-347/? E/AEC_PORT: aec_port_init kur aec should be initialized
2019-04-11 15:34:03.057 347-347/? E/mm-camera: stats_port_init: E
2019-04-11 15:34:03.057 347-347/? E/mm-camera: stats_port_init: X
2019-04-11 15:34:03.057 347-347/? E/mm-camera: cpp_module_start_session:270, info: starting session 2
2019-04-11 15:34:03.093 347-347/? E/mm-camera: cpp_module_start_session:314, info: cpp_thread created.
2019-04-11 15:34:03.093 347-347/? E/mm-camera: cpp_module_start_session:317, info: session 2 started.
2019-04-11 15:34:03.093 347-347/? E/mm-camera: c2d_module_start_session:218, info: starting session 2
2019-04-11 15:34:03.097 347-32191/? E/mm-camera: companion_check_crc:1139 iteration = 0, CRC from CC = 0x50ee79d2, CRC from FROM = 0x50ee79d2
2019-04-11 15:34:03.098 347-347/? E/mm-camera: af_module_set_session E kur module 0xacf306a0 sessionid=131072
2019-04-11 15:34:03.098 347-347/? E/AF_PORT: kur init TsAf 0x45b4312d 
2019-04-11 15:34:03.098 347-32198/? E/mm-camera-img: module_imglib_msg_thread: __ZZZZ__: E
2019-04-11 15:34:03.098 347-32198/? E/mm-camera-img: module_imglib_msg_thread:62 abort 0
2019-04-11 15:34:03.098 347-32198/? E/mm-camera-img: module_imglib_msg_thread:98] MOD_IMG_MSG_ANY
2019-04-11 15:34:03.098 347-32198/? E/mm-camera: module_cac_client_allocate_cac_buffer:47] E ref_count 0
2019-04-11 15:34:03.098 347-32198/? E/mm-camera-img: cac3_comp_alloc:1121] ptr 0x8cf91c9b
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] Wrong Phase AF CAL Info. Phase AF Disabled
2019-04-11 15:34:03.098 347-347/? E/mm-camera:  [_paf_] Unknown TUNE_VERSION: 0
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] ---------------------------------------------------------------------
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] AF Version : 0x3000
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] AF Cal: PAN: 0x0, MAC: 0x0, OFFSET: 0, PHASE-HEAD: 0x0(0)
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] Check OCR mode : Enabled(0), Dir(0)
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] AF Mode (0x3): PREVIEW CAF
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] Sensor image size ( 0 0 )
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] PafStatValid: 0 , CafStatValid: 0 
2019-04-11 15:34:03.098 347-347/? E/mm-camera: [cgAF] Window Setting ERROR : Sensor Size(0, 0)
2019-04-11 15:34:03.098 347-32191/? E/mm-camera: companion_check_crc:1139 iteration = 1, CRC from CC = 0x9b6bc25e, CRC from FROM = 0x9b6bc25e
2019-04-11 15:34:03.099 347-347/? I/mm-camera: server_process_hal_event:__DBG__ X sucess event id=1
2019-04-11 15:34:03.099 351-18006/? W/mm-camera-intf: mm_camera_open:  opened, break out while loop
2019-04-11 15:34:03.099 351-18006/? I/mm-camera-intf: mm_camera_socket_create: socket_fd =8
2019-04-11 15:34:03.099 347-32191/? E/mm-camera: companion_check_crc:1139 iteration = 2, CRC from CC = 0xa8bab7ca, CRC from FROM = 0xa8bab7ca
2019-04-11 15:34:03.100 347-32191/? E/mm-camera: companion_check_crc:1139 iteration = 3, CRC from CC = 0x4b2c7c7a, CRC from FROM = 0x4b2c7c7a
2019-04-11 15:34:03.101 347-32191/? E/mm-camera: companion_check_crc:1139 iteration = 4, CRC from CC = 0xa97ebe32, CRC from FROM = 0xa97ebe32
2019-04-11 15:34:03.102 347-32191/? E/mm-camera: companion_check_crc:1124 iteration = 5 / 0, CRC from CC = 0xe84adf4c, CRC from FROM = 0xe84adf4c
2019-04-11 15:34:03.106 347-32191/? E/mm-camera: companion_check_crc:1124 iteration = 5 / 1, CRC from CC = 0xdf4073cf, CRC from FROM = 0xdf4073cf
2019-04-11 15:34:03.106 2353-2353/org.lineageos.lockclock D/WeatherUpdateService: onCreate
2019-04-11 15:34:03.109 347-32191/? E/mm-camera: companion_check_crc:1124 iteration = 5 / 2, CRC from CC = 0x1b67e064, CRC from FROM = 0x1b67e064
2019-04-11 15:34:03.111 2353-2353/org.lineageos.lockclock D/WeatherUpdateService: Service started, but shouldn't update ... stopping
2019-04-11 15:34:03.112 347-32191/? E/mm-camera: companion_check_crc:1124 iteration = 5 / 3, CRC from CC = 0xba8b79ae, CRC from FROM = 0xba8b79ae
2019-04-11 15:34:03.113 2353-2353/org.lineageos.lockclock D/WeatherUpdateService: onDestroy
2019-04-11 15:34:03.114 347-32198/? E/libaprpmem:  Ion allocation success virtaddr : ret=2680975360 fd=28 heapid=1048576
2019-04-11 15:34:03.115 347-32198/? E/cac3:  [cac3_buffer_latency] Allocated 0x9fcc7000, mem size 3997696 bytes from ION Heap ID 20: 16 ms 
2019-04-11 15:34:03.115 347-32191/? E/mm-camera: companion_check_crc:1124 iteration = 5 / 4, CRC from CC = 0x5b7bf110, CRC from FROM = 0x5b7bf110
2019-04-11 15:34:03.116 347-32191/? E/mm-camera: companion_check_crc:1124 iteration = 5 / 5, CRC from CC = 0xbe1c44e6, CRC from FROM = 0xbe1c44e6
2019-04-11 15:34:03.117 347-32198/? E/cac3:  [cac3_buffer_latency] memset for mem size 3997696 bytes: 2 ms 
2019-04-11 15:34:03.118 347-32191/? E/mm-camera: companion_check_crc:1139 iteration = 6, CRC from CC = 0xe98d0230, CRC from FROM = 0xe98d0230
2019-04-11 15:34:03.118 347-32191/? E/mm-camera: companion_check_crc:1147 is_supported = 0xFDDF
2019-04-11 15:34:03.118 347-32191/? E/mm-camera: companion_process:2155 is_supported = 0xFDDF
2019-04-11 15:34:03.118 347-32191/? E/mm-camera: companion_load_master:1163 Loading master
2019-04-11 15:34:03.118 347-32191/? E/mm-camera: companion_get_info:1555 Read device id on i2c
2019-04-11 15:34:03.119 347-32191/? E/mm-camera: companion_get_info:1564 Device id on i2c = 73c1
2019-04-11 15:34:03.119 347-32191/? E/mm-camera: companion_process:2171 End load firmware !
2019-04-11 15:34:03.123 347-32198/? E/libaprpmem:  Ion allocation success virtaddr : ret=2672984064 fd=30 heapid=1048576
2019-04-11 15:34:03.123 347-32198/? E/cac3:  [cac3_buffer_latency] Allocated 0x9f528000, mem size 7991296 bytes from ION Heap ID 20: 6 ms 
2019-04-11 15:34:03.125 351-18006/? E/qomx_image_core: OMX_Init:85] Complete 1











2019-04-11 15:34:03.492 347-32221/? E/mm-camera-sensor: module_sensor_stop_session:1252 session 2
2019-04-11 15:34:03.492 347-32221/? E/mm-camera-sensor: module_sensor_stop_session: __ZZZZ__: E 1253= 
2019-04-11 15:34:03.493 347-32221/? E/mm-camera-sensor: module_sensor_deinit_session: E __ZZZZ__: 1129= 
2019-04-11 15:34:03.493 347-32221/? E/mm-camera: companion_release_interface:1656 Release second subdev node
2019-04-11 15:34:03.522 347-32221/? E/mm-camera: companion_close:2290 Enter
2019-04-11 15:34:03.522 347-32221/? E/mm-camera: companion_post_msg_to_thread:497 msg.type=0
2019-04-11 15:34:03.522 347-32191/? E/mm-camera-sensor: companion_thread_process_pipe_message:269 COMPANION_THREAD_MSG_ABORT: companion_thread exiting..
2019-04-11 15:34:03.522 347-32221/? E/mm-camera: companion_close:2304 companion_thread is joined.
2019-04-11 15:34:03.523 347-32221/? E/mm-camera: companion_close:2331 Exit
2019-04-11 15:34:03.523 347-32221/? E/mm-camera-sensor: module_sensor_deinit_session: __ZZZZ__: Before unload lib 1149= 
2019-04-11 15:34:03.523 347-32221/? E/mm-camera-sensor: module_sensor_deinit_session: __ZZZZ__: After unload lib 1151= 
2019-04-11 15:34:03.523 347-32221/? E/mm-camera-sensor: module_sensor_deinit_session: __ZZZZ__: X 1167= 
2019-04-11 15:34:03.523 347-32221/? E/mm-camera-sensor: module_sensor_stop_session: __ZZZZ__: X 1299= 
2019-04-11 15:34:03.523 347-32221/? E/mm-camera: ispif_stop_session: __ZZZZ__: E 199= 
2019-04-11 15:34:03.523 347-32221/? E/mm-camera: ispif_stop_session: __ZZZZ__: After memset 208= 
2019-04-11 15:34:03.523 347-32221/? E/camera-llv: llv_release, E
2019-04-11 15:34:03.523 347-32221/? E/mm-camera: isp_thread_async_task_stop: __ZZZZ__: E 320= 
2019-04-11 15:34:03.523 347-32221/? E/mm-camera: isp_thread_async_task_stop: __ZZZZ__: Ater thread started 325= 
2019-04-11 15:34:03.523 347-32221/? E/mm-camera: isp_thread_async_task_stop: __ZZZZ__: Before sem post 339= 
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: isp_thread_async_task_stop: __ZZZZ__: After sem post 341= 
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: isp_thread_async_task_stop: __ZZZZ__: After thread join 343= 
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: isp_thread_async_task_stop: X, session_id = 2
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: stats_module_stop_session: __ZZZZ__: E 301= 
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: stats_module_stop_session: list =0xac61e190, remove port =0xacef5fc0 name=stats_sink from module=0xacf30520, name=stats
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: stats_module_stop_session: 1 port =0xacef5fc0 name=stats_sink 
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: stats_port_deinit: E
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: stats_port_deinit: __dbg private free
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: stats_port_deinit: X
2019-04-11 15:34:03.524 347-32221/? E/mm-camera: stats_module_stop_session: 2 port =0xacef5fc0 name=stats_sink 
2019-04-11 15:34:03.525 347-32221/? E/AEC_PORT: aec_port_deinit kur deinit calledon 0xaedf0200 
2019-04-11 15:34:03.526 347-32221/? E/mm-camera: stats_module_stop_session: 3 port =0xacef5fc0 name=stats_sink 
2019-04-11 15:34:03.526 347-32221/? E/mm-camera: stats_module_stop_session: __ZZZZ__: X 339= 
2019-04-11 15:34:03.526 347-32221/? E/mm-camera: cpp_module_stop_session: __ZZZZ__: E 324= 
2019-04-11 15:34:03.526 347-32221/? E/mm-camera: cpp_module_stop_session:334, info: stopping session 2 ...
2019-04-11 15:34:03.526 347-32196/? E/mm-camera: cpp_thread_process_pipe_message:361, CPP_THREAD_MSG_ABORT: cpp_thread exiting..
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: cpp_module_stop_session:365, info: session 2 stopped.
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: c2d_module_stop_session: __ZZZZ__: E 285= 
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: c2d_module_stop_session:295, info: stopping session 2 ...
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: c2d_module_stop_session:300, info: stopping c2d_thread...
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: c2d_module_post_msg_to_thread:354, msg.type=1
2019-04-11 15:34:03.528 347-32197/? E/mm-camera: c2d_thread_process_pipe_message:453, C2D_THREAD_MSG_ABORT: c2d_thread exiting..
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: c2d_module_stop_session:312, closing c2d subdev...
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: c2d_module_stop_session:334, info: session 2 stopped.
2019-04-11 15:34:03.528 347-32221/? E/mm-camera: module_cac_client_release_cac_buffer:90] E, ref_count 1
2019-04-11 15:34:03.528 347-32221/? E/mm-camera-img: cac3_comp_dealloc:1153] ptr 0x8cf91c9b
2019-04-11 15:34:03.529 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9c6d4000, mem size 4063232 bytes: 0 ms 
2019-04-11 15:34:03.530 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9ce94000, mem size 4063232 bytes: 0 ms 
2019-04-11 15:34:03.530 3719-3879/com.qrcorde.scan.barcode.reader.generator I/PresentationSystem: not needQuiet
2019-04-11 15:34:03.530 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9cab4000, mem size 4063232 bytes: 0 ms 
2019-04-11 15:34:03.531 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9fcc7000, mem size 3997696 bytes: 0 ms 
2019-04-11 15:34:03.532 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9f528000, mem size 7991296 bytes: 1 ms 
2019-04-11 15:34:03.534 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9ed89000, mem size 7991296 bytes: 1 ms 
2019-04-11 15:34:03.535 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9e582000, mem size 8417280 bytes: 1 ms 
2019-04-11 15:34:03.536 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9e1b2000, mem size 3997696 bytes: 0 ms 
2019-04-11 15:34:03.539 347-32221/? E/cac3:  [cac3_buffer_latency] memfree for 0x9d274000, mem size 15982592 bytes: 2 ms 
2019-04-11 15:34:03.539 347-32221/? E/cac3:  [cac3latency] cac3_destroy_buffers: 10 ms 
2019-04-11 15:34:03.539 347-32198/? E/mm-camera-img: module_imglib_msg_thread:109] X  a9291970
2019-04-11 15:34:03.539 347-32199/? E/mm-camera-img: module_imglib_msg_thread:109] X  a227f970
2019-04-11 15:34:03.539 347-32221/? I/mm-camera: mct_pipeline_stop_session: __ZZZZ__: X 1677= 
2019-04-11 15:34:03.539 347-347/? I/mm-camera: mct_controller_destroy: __ZZZZ__: X 218= 
2019-04-11 15:34:03.539 347-347/? I/mm-camera: server_process_hal_event:__DBG__ X sucess event id=2
2019-04-11 15:34:03.539 347-347/? E/mm-camera: main: __ZZZZ___ Result del session Entry
2019-04-11 15:34:03.539 347-347/? E/mm-camera: main: __ZZZZ___ Result del session Exit

logcat的这两个块是红色的,最后一个关闭了应用程序

1 个答案:

答案 0 :(得分:0)

堆栈跟踪并不完全有用,但是stdlib.h中的_surface可能是null ...因此,我建议添加关键字SurfaceHolder.Callback:< / p>

final

...,以便对它的引用将在范围更改后继续存在。

PS:人们可以为模拟器设置通用的网络摄像头。