Using Azure's Spatial Anchors library

Hi all!

I'm trying to add cloud anchors to an AR project. Currently, there aren't that many options to do this. I spent some time looking into Google's cloud anchors and quickly found out that you can't serialize them and the system is more targeted to sharing short-lived anchors between users rather than populating anchors around a user from a server, which is more like what I want to do.

So, I turned to Azure Spatial anchors which seem more like what I want to do. However, Microsoft doesn't seem to provide any easy-access nuget or something like that for Xamarin projects. In their FAQ they do say

Q: Does it work with Xamarin?
A: Yes. While we don't provide a Xamarin SDK, we expect developers can use Azure Spatial Anchors in their Xamarin apps by integrating with the Azure Spatial Anchors API.

Although, to be honest, I don't know what they mean by that. What API? I haven't found a DLL or nuget that would provide me with the functions in their demos. I've considered using the AAR in mvnrepository for spatialanchors but that seems easier said than done.

Any of you have any experience on making Spatial anchors work? Did you use an AAR? Did you manage to download the dependencies with gradle? Am I missing an obvious method to integrate the API into my project? Do these methods work cross-platform?

Sidenote: I know about a package called Microsoft.Azure.SpatialAnchors.WinCPP. I believe that that's intended for Unity alone although I'm reading a blogpost about it to see if I can use it in my Android App

Answers

  • mikelormikelor Member

    Hey @Axel_ib, any progress on this? Was just starting to investigate, but no luck yet.

  • Axel_ibAxel_ib Member
    edited April 24

    Hi @mikelor!

    Not much progress so far. I decided to import the jar that Microsoft uses in their sample for Java Android. I did manage to fix all of the compile conflicts but I ended up running into many unresolved functions at runtime. I had the impression that I was just plugin leaky holes with my fingers. I'll have to work on this project again soon and I'll see what progress can be made using the jar as a external reference jar and using a custom made jar as a bridge library.

    If you do happen to make it work let me know as I'm still looking for a solution

Sign In or Register to comment.