react-native-ar / react-native-arkit

React Native binding for iOS ARKit
MIT License
1.73k stars 139 forks source link

[Question] Is there getCameraAngles() method ? #131

Closed davidmichaelhogan closed 6 years ago

davidmichaelhogan commented 6 years ago

Is there a way to get the camera eulerAngles as stated in the original docs: https://developer.apple.com/documentation/arkit/arcamera/2866109-eulerangles

Thank you!

macrozone commented 6 years ago

there is ARKit.getCamera which should include the eulerAngles

EDIT: i updated the readme to mention the function, thx!

davidmichaelhogan commented 6 years ago

It seems like it's only returning some values properly... Ex. notice the zeros, they don't change. Any idea?

{ orientation: { x: 0, z: 0, w: 0.9945524334907532, y: -0.1042373776435852 }, position: { z: -0.3167085647583008, y: -0.19516338407993317, x: 0.24263806641101837 }, direction: { z: -0.5226291418075562, y: -0.8453337550163269, x: 0.11076854169368744 }, eulerAngles: { z: 0, y: -0.20885413885116577, x: 0 }, rotation: { x: 0, z: 0, w: 0.20885439217090607, y: -0.9999991655349731 } }