I’m new to RealityKit, so perhaps I am asking something very obvious, but I couldn’t wrap my mind around it.
Given that I have a ModelEntity
(in my case, a cube), anchored to the world (in my case, on an image anchor) in an iOS app, and I install the rotation gesture to it:
<code>func installGestures(on object: ModelEntity, arView: ARView) {
object.generateCollisionShapes(recursive: true)
arView.installGestures([.rotation], for: object)
}
</code>
<code>func installGestures(on object: ModelEntity, arView: ARView) {
object.generateCollisionShapes(recursive: true)
arView.installGestures([.rotation], for: object)
}
</code>
func installGestures(on object: ModelEntity, arView: ARView) {
object.generateCollisionShapes(recursive: true)
arView.installGestures([.rotation], for: object)
}
when I rotate it using a two-finger gesture, it always rotates around the same axis, even if I perform the two-finger gesture while “facing” a different side of the ModelEntity
. How do I switch the rotation axis while in the ARView
?