How to determine the height of the iPhone (for use in an augmented reality game)?

I am working on finding an iPhone device in three-dimensional space.

I can use lat / long to detect a physical location, I can use a magnetometer to find out the direction they are facing, and I could use an accelerometer to find out how their device is oriented, but I can 'Define a way to get the height of the device with gender.

In particular, I need to know if the user is crouching or raising his hand to the ceiling (the difference is about 2 meters / 6 feet).

I posted a more detailed description of what I'm trying to do on my blog: http://pushplay.net/blog_detail.php?id=36

I would love any suggestions on how to even fake such information. I really need interactivity and movements that require dodging and bouncing around, but just letting someone sit back and tilt the phone - it’s kind of like people can “cheat” a game using Wii ...

+7
iphone augmented-reality 3d
source share
3 answers

Closest I could see that you get to what you are looking for using the accelerometer / magnetometer as an inertial tracker. You will have to calibrate the user's initial position at startup to the “base” position, and then continuously project the sensors onto the background stream to build a motion model. This post talks about increasing the default sample rate of the accelerometer functions so that you can get a pretty fine-grained picture of the user's movements.

I’m not sure that this will solve your concern that people simply catch the device to perform the desired action, but you will have to balance between being too strict in interpreting the movements and taking into account the differences in movement.

+7
source share

CoreLocation stuff gives you elevation as well as lat / long, so you can use it, although there are some significant issues with this:

  • Will not work well indoors (not a problem for Sat Nav, this is a problem for games)
  • Your users will have to “calibrate” (perhaps placing the phone on the floor) in every place they use!
  • In fact, you will need to start keeping a list of “previously calibrated places” ... which can vary greatly in only one house (for example, several rooms and floors). May interfere with the game.
  • It cannot be used when moving vehicles (grass, airplanes, cars ... even walking), because a change in height occurs so often.

Therefore, I would think that using the accelerometer as a proxy server for altitude is a much more preferable route than determining the absolute altitude.

+1
source share

I am not familiar with iphone. But this may require a hardware addition. (which you probably don't want to do). Thinking about it, I only know how the light or a more specific laser passes. You shoot the laser on the floor and record the time it takes to return. Actually there is not much to combine this equipment, and I am sure that the iphone has connections for peripherals. If osmeone cannot surpass me, I say that there is no way to do this with the image.

0
source share

All Articles