-
Notifications
You must be signed in to change notification settings - Fork 402
Location Service problem with ARCore #14
Comments
Thanks for the bug report. We're looking into this and will get back to you when we have more info. |
@dblatner could you provide a repro project where you expect Unity's LocationService to work but it is not working? That will help us immensely in tracking this down. |
Hello @chaosemer, @nathanmartz, I uploaded an example ARCore Unity project : https://github.com/dblatner/unity-arcore-locationservice It's basically the HelloAR example, then I included two scripts. One for getting the geolocation and one for displaying it on the canvas. I checked the problem with the Samsung S8 phone. I double-checked the location settings on the phone but the problem persists. Please let me know, if the problem occurs on your phone too or not. Best regards |
The issue is that once you enable ARCore, Android Permissions are no longer requested automatically, and you do not have the location permission. You can request the location permission at runtime with AndroidPermissionsManager.RequestPermission(), passing "android.permission.ACCESS_FINE_LOCATION". I hope this helps! If so, please feel free to close this issue. |
I'm assuming your issue is fixed due to the lack of responses. Please reopen if you're still having an issue. |
Hello! I was running into this myself and wanted to add a note since this was the only visible thread for this problem. If you have to chain multiple permissions, I found I needed to add WaitForCompletion() in order to make both requests pop up. var firstPermission = AndroidPermissionsManager.RequestPermission("android.permission.ACCESS_FINE_LOCATION");
firstPermission.WaitForCompletion();
var secondPermission = AndroidPermissionsManager.RequestPermission("android.permission.CAMERA");
secondPermission.WaitForCompletion(); |
I faced the same problem . I have an S10 and using ARCore v1.11 . Although , the problem appears only on the editor and instant preview . On runtime i get GPS data . |
ARCore seems to combine a lot of sensor data for the positioning / motion tracking of the device.
However, if I want to access the GPS data through the LocationService it gives me the status disabled for LocationService and any access on the latitude/longitude does not return any plausible values.
Does anyone know why this is happening? How can I access the coordinates of the LocationService?
The text was updated successfully, but these errors were encountered: