I want to move objects on the iPhone screen (rectangle, circle, etc.) by moving the iPhone. For example, I move the iPhone along the X axis, and the object moves along the X axis. The same goes for the Y, Z axis.
How can i do this? Can I get an algorithm for this?
Thank.
PS: Iโve been looking for some time and it seems that this is possible with the help of an accelerometer.
iphone xcode accelerometer distance
MeIr Jul 11 2018-11-11T00: 00Z
source share