安卓应用中,Manifest中权限已打开,主程序中使用Unity提供的申请权限方法来申请相机权限并调用,最终导出的APK在自己手机上能正常使用(Android12版本),但是在开发板RK3566(Android11版本)上检测不到相机,除相机以外的功能都能正常使用。 想问,可能有哪些解决办法? 调用相机时候,报错日志如下: 2023-10-31 09:33:06.316 2304-2328 CameraManagerGlobal com.djd.test_for_unity I Connecting to camera service 2023-10-31 09:33:06.316 495-510 ActivityTaskManager system_server I START u0 {act=android.content.pm.action.REQUEST_PERMISSIONS pkg=com.android.permissioncontroller cmp=com.android.permissioncontroller/.permission.ui.GrantPermissionsActivity (has extras)} from uid 10131 2023-10-31 09:33:06.323 360-1255 ServiceManager cameraserver W Permission failure: android.permission.CAMERA_OPEN_CLOSE_LISTENER from uid=10131 pid=2304 2023-10-31 09:33:06.342 2304-2374 AudioTrack com.djd.test_for_unity D stop(18): called with 66560 frames delivered 2023-10-31 09:33:06.348 495-510 ActivityTaskManager system_server W Tried to set launchTime (0) < mLastActivityLaunchTime (59488) 2023-10-31 09:33:06.414 1766-1766 GrantPermi...nsActivity com.android.permissioncontroller V Permission grant result requestId=-6304222151912979741 callingUid=10131 callingPackage=com.djd.test_for_unity permission=android.permission.CAMERA isImplicit=false result=5 2023-10-31 09:33:06.436 228-228 gralloc4 and...raphics.allocator@4.0-service D [File] : hardware/rockchip/libgralloc/bifrost/src/hidl_common/Allocator.cpp; [Line] : 149; [Func] : allocate; got new private_handle_t instance @0xb400007be8c2e070 for buffer 'screenshot'. share_fd : 8, share_attr_fd : 9, flags : 0x4, width : 1920, height : 1080, req_format : 0x1, producer_usage : 0x333, consumer_usage : 0x333, internal_format : 0x0, stride : 1920, byte_stride : 0, internalWidth : 0, internalHeight : 0, alloc_format : 0x1, size : 8294400, layer_count : 1, backing_store_size : 8294400, backing_store_id : 979252543659, allocating_pid : 228, ref_count : 1, yuv_info : 0 2023-10-31 09:33:06.436 228-228 gralloc4 and...raphics.allocator@4.0-service D plane_info[0]: offset : 0, byte_stride : 7680, alloc_width : 1920, alloc_height : 1080 2023-10-31 09:33:06.436 228-228 gralloc4 and...raphics.allocator@4.0-service D plane_info[1]: offset : 0, byte_stride : 0, alloc_width : 0, alloc_height : 0 2023-10-31 09:33:06.482 288-400 APM_AudioPolicyEngine audioserver W getDevicesForStrategy() unknown strategy: -1 2023-10-31 09:33:06.483 288-400 chatty audioserver I uid=1041(audioserver) ApmOutput identical 1 line 2023-10-31 09:33:06.483 288-400 APM_AudioPolicyEngine audioserver W getDevicesForStrategy() unknown strategy: -1 2023-10-31 09:33:06.484 495-2121 system_server system_server I oneway function results will be dropped but finished with status OK and parcel size 4 2023-10-31 09:33:06.500 495-2121 WindowManager system_server V getPackagePerformanceMode -- ComponentInfo{com.djd.test_for_unity/com.unity3d.player.UnityPlayerActivity} -- com.djd.test_for_unity -- mode=0 2023-10-31 09:33:06.506 2304-2328 Compatibil...geReporter com.djd.test_for_unity D Compat change id reported: 147600208; UID 10131; state: ENABLED |
-
35.77 KB, 下载次数: 0, 下载积分: 灯泡 -1 , 经验 -1