react-native-arkit icon indicating copy to clipboard operation
react-native-arkit copied to clipboard

ARKit.snapshot() and ARKit.snapshotCamera() crash when get called

Open vasinl124 opened this issue 7 years ago • 7 comments

I tried to use these 2 functions last night and got crashed ever time these 2 get called. I tried this with iOS9.3 on iPhone X.

screen shot 2018-04-02 at 8 47 12 pm

vasinl124 avatar Apr 03 '18 14:04 vasinl124

I'm experiencing the same

jwanga avatar Jun 26 '18 15:06 jwanga

which version do you use?

can you try passing an empty object for options?

ARKit.snapshot({}) (altough this should be fixed afair)

macrozone avatar Jun 27 '18 12:06 macrozone

@macrozone unfortunately, that did not fix the issue for me.

jwanga avatar Jun 27 '18 17:06 jwanga

@jwanga which version do you use and are there any more logs?

macrozone avatar Jun 27 '18 19:06 macrozone

@macrozone Hello, I'm experiencing the same issue.

Produced by console: 2018-07-13 15:31:23.597 [info][tid:com.facebook.react.JavaScript] Running application "---" with appParams: {"rootTag":1,"initialProps":{}}. DEV === true, development-level warning are ON, performance optimizations are OFF

Main Thread Checker: UI API called on a background thread: -[UIView bounds] PID: 2084, TID: 208570, Thread name: (none), Queue name: com.apple.root.default-qos, QoS: 21 Backtrace: 4 Pyle 0x0000000104a79334 -[RCTARKit cropImage:toSelection:] + 164 5 Pyle 0x0000000104a78f28 -[RCTARKit getSnapshotCamera:] + 456 6 Pyle 0x0000000104a8319c __49-[RCTARKitManager snapshotCamera:resolve:reject:]_block_invoke + 236 7 libdispatch.dylib 0x00000001077e91dc _dispatch_call_block_and_release + 24 8 libdispatch.dylib 0x00000001077e919c _dispatch_client_callout + 16 9 libdispatch.dylib 0x00000001077f5200 _dispatch_queue_override_invoke + 968 10 libdispatch.dylib 0x00000001077fa7c8 _dispatch_root_queue_drain + 604 11 libdispatch.dylib 0x00000001077fa500 _dispatch_worker_thread3 + 136 12 libsystem_pthread.dylib 0x0000000181503fac _pthread_wqthread + 1176 13 libsystem_pthread.dylib 0x0000000181503b08 start_wqthread + 4

davidmichaelhogan avatar Jul 13 '18 19:07 davidmichaelhogan

This error is caused by missing camera roll permissions. As of ios11, add the following keys to your info.plist

  • Privacy - Camera Usage Description
  • Privacy - Photo Library Usage Description
  • Privacy - Photo Library Additions Usage Description
  • Privacy - Microphone Usage Description

ambewas avatar Jul 15 '18 10:07 ambewas

@ambewas, this solved my problem. Thanks!

cineconcerts avatar Jul 20 '18 23:07 cineconcerts