Search Unity

AR Points of interest via geo location/GPS

Discussion in 'AR/VR (XR) Discussion' started by SpiderJones, Nov 3, 2018.

  1. SpiderJones

    SpiderJones

    Joined:
    Mar 29, 2014
    Posts:
    246
    I'm developing an AR app that displays points of interest to the user based on their location. The user gets to the GPS location and an object is displayed in the app over their camera feed. I've been experimenting with Mapbox and it's pretty cool, but GPS accuracy isn't great and the objects move or float a lot, not sure if this is due to Mapbox, or Unity, or me.

    I'm thinking I may need to combine something like Mapbox with a more surface recognition AR approach. So Mapbox for the map and geo location, then some thing like Vuforia for displaying the AR object.

    Any thoughts or tips?
     
  2. peter-motive

    peter-motive

    Joined:
    Jul 16, 2016
    Posts:
    26
    That's just GPS. Not Mapbox or Unity.

    There are a number of options, some are more/less technical than others:

    1) Utilize ARKit/ARCore to stabilize the Asset once you switch to Camera View. This will depend on the minimum specs of your user's devices. Older phones might not have this.

    2) Use an AR asset that floats/can fly. That way you don't need to worry about it being on a surface.

    3) Have a user get within a radius of a GPS point, scan for surface detection and then place the AR asset. This might change your game mechanic.

    4) Have the user get within a radius of a GPS point and then place the AR asset at an angle and position relative to the user.

    5) Image recognition - You mentioned Vuforia. In this case you won't need GPS. However, you will need reliable image markers that will remain consistent over time or that you can make sure will be there when you need them to be. This depends on your project.

    6) AR Cloud - Relocatization could be used if you have the ability to scan the area in advance. There are a few SDKs available that you could check out.

    7)Write a GPS smoothing algorithm or find a 3rd party plugin that will do that.

    HTH
     
    SpiderJones and LokeshKosuri like this.
  3. LokeshKosuri

    LokeshKosuri

    Joined:
    Sep 4, 2018
    Posts:
    3
    Hi @splitpete ,

    We are also trying to achieve the same using geo coordinates placing a game object at particular lat n long.
    but we want to place the object at particular position not inside a radius, is there any other alternative that we can try with?

    we tried this using mapbox also but due to GPS accuracy isn't great and the objects move or float a lot.

    Any thoughts or tips?
     
  4. peter-motive

    peter-motive

    Joined:
    Jul 16, 2016
    Posts:
    26
    Hi LokeshKosuri,

    As far as I know, the ways I outlined above are your options. I am not aware of anything else. If you don't want to use a radius, then options 1, 2, 6 and possibly 7 are what you need to investigate.

    Option 5 works well but you need to make sure the image you are using is easy for your app to recognize. ARCore has a built-in command line tool which will give a score to say if an image is good or not to use.

    Keep in mind that depending on what you choose, you may be limiting the number of phones that can run your app. Certain tech is only available to newer phones. It's worth keeping in mind the phones you are targeting when choosing an option.

    In my experience making AR projects that use GPS, accuracy is important but hyper accuracy usually isn't. The user will spend the majority of their time walking around. Making the walk more interesting will help engage and retain users. You can spend a lot of time/budget making something hyper accurate and forget about the rest of the experience. If so, people will stop using the app because you made them walk too far or the walk wasn't interesting enough.

    At the end of the day, It depends on your requirements.

    HTH
     
    wunder-ilmari and LokeshKosuri like this.
  5. SpiderJones

    SpiderJones

    Joined:
    Mar 29, 2014
    Posts:
    246
    Hi, thank you for your help. I'm using Mapbox for placing the GPS locations and attach key value pairs. Then using Mapbox I display a top down map of the user's location and the location of the gps points. When the user is within a distance from the point they are prompted to find a plane and then my app renders a AR object on the plane. I'm still working on the planar AR and Mapbox does have an API for that, but I'm might do it using Unities built in tools. Thanks for your advice.
     
  6. danieilng21

    danieilng21

    Joined:
    Mar 11, 2018
    Posts:
    5
    Hi Spider Jones, I just found out Mapbox and saw your post, generally I would like to know if you have any experience using last know location Class AbstractLocationProvider (which is the only thing I'm interested in for my project)? Also, is Mapbox free if the app is free to use but those who access the data is charged but has nothing to do with the app GPS location?

    Btw, as long as you have long and lat, you can check out youtube for awesome gps AR videos (using Vuforia if I am not mistaken) and stackoverflow for radius calculation https://stackoverflow.com/questions/365826/calculate-distance-between-2-gps-coordinates