2021/08/04 22:37:01.720 21828 22859 Error native E0804
22:37:01.720008 22859 cameras_async.cc:261] FAILED_PRECONDITION:
2021/08/04 22:37:01.720 21828 22859 Error native ARCoreError: third_party/arcore/ar/infrastructure/android/cameras.cc:330
2021/08/04 22:37:01.720 21828 22859 Error native Cannot runtime configure camera 0 unless it's closed or streaming.
2021/08/04 22:37:01.786 21828 22500 Error native E0804
22:37:01.786095 22500 error_policy_util.cc:264]
2021/08/04 22:37:01.786 21828 22500 Error native
################ ARCore Native Error ##################
2021/08/04 22:37:01.786 21828 22500 Error native BUILD_CHANGELIST:380643917
2021/08/04 22:37:01.786 21828 22500 Error native BUILD_BASELINE_CHANGELIST:375841813
2021/08/04 22:37:01.786 21828 22500 Error native
################### Stack Trace Begin ################
2021/08/04 22:37:01.786 21828 22500 Error native ARCoreError: third_party/arcore/ar/infrastructure/android/cameras.cc:330 https://cs.corp.google.com/piper///depot/google3/third_party/arcore/ar/infrastructure/android/cameras.cc?g=0&l=330
2021/08/04 22:37:01.786 21828 22500 Error native ARCoreError: third_party/arcore/ar/infrastructure/cameras_async.cc:161 https://cs.corp.google.com/piper///depot/google3/third_party/arcore/ar/infrastructure/cameras_async.cc?g=0&l=161
2021/08/04 22:37:01.786 21828 22500 Error native ARCoreError: third_party/arcore/ar/infrastructure/android_data_source.cc:635 https://cs.corp.google.com/piper///depot/google3/third_party/arcore/ar/infrastructure/android_data_source.cc?g=0&l=635
2021/08/04 22:37:01.786 21828 22500 Error native ARCoreError: third_party/arcore/ar/core/session.cc:1735 https://cs.corp.google.com/piper///depot/google3/third_party/arcore/ar/core/session.cc?g=0&l=1735
2021/08/04 22:37:01.786 21828 22500 Error native ARCoreError: third_party/arcore/ar/core/c_api/session_lite_c_api.cc:76 https://cs.corp.google.com/piper///depot/google3/third_party/arcore/ar/core/c_api/session_lite_c_api.cc?g=0&l=76
2021/08/04 22:37:01.786 21828 22500 Error native
################### Stack Trace End #################
다른 사람이 작업하던 코드를 받아서 AR 기능을 추가하는 작업을 하는데 최초 실행은 잘 되고, 재실행시 위와 같은 에러가 발생하는 일이 있었다. 여차저차 해서 원인을 찾아 냈는데, 원인은 WebCamTexture 기능 때문이었는다.
최초엔 Permission 때문에 작동을 안했다가, 재실행시 Camera 소유권을 AR 보다 먼저 가져가면서 AR 쪽에서 에러가 난 것으로 추측된다.
위와 비슷한 에러가 뜬다면 Camera 를 사용하는 기능이 한번에 여러개 켜져있는 것은 아닌지 확인해 보기 바란다.
댓글