Select to view content in your preferred language

Is it Possible to Load Indoors Data Through the Persistent Data Path in Unity?

70
1
2 weeks ago
NickGuzi11
New Contributor

Hello all,

In the past have successfully loaded  ArcGIS3DObjectSceneLayers through .slpks from my project's PersistentDataPath. The simple script I created to load these in my scenes looks like so:

try
        {
            var buildingLayer = new Esri.GameEngine.Layers.ArcGIS3DObjectSceneLayer(
                Application.persistentDataPath + "/file_name.slpk",
                "Layer Name", 1.0f, true, "");
            arcGISMapComponent.View.Map.Layers.Add(buildingLayer);
            Debug.Log("Building Layer loaded successfully.");
        }
        catch (Exception ex)
        {
            Debug.LogError($"Error loading Building Layer: {ex.Message}");
        }  

 I was curious if it would be possible to do this with indoors data served through an .slpk in my PersistentDataPath? Or if the Unity SDK is incapable of handling indoors data?

 

Thank you in advance!

- Nick

0 Kudos
1 Reply
MichaelBranscomb
Esri Frequent Contributor

Hi,

It would be great to find out more about your app/project and capture your requirements in our backlog - you can email me at: mbranscomb@esri.com.

By indoors data, I'm assuming you're referring to ArcGIS Indoors and the supporting data model. The Indoors data model is stored in a geodatabase and accessed via maps/scenes and feature layers. Unfortunately, our Unity Maps SDK doesn't currently support feature layers, nor does it have any specific API for working with ArcGIS Indoors data (often referred to as floor-aware). If the floor aware layers are published as services then you may be able to work with the REST endpoint and we have various samples for this, although the samples don't specifically cover navigating any data relationships. Even if you want the app to work offline, you could potentially query the mobile .geodatabase file, which is based on SQLite. 

You mention .slpk files - those are specific to I3S 3D scene layers, including Building, 3D Object, and Integrated Mesh layer types. It looks like you already have some 3D data based on your code snippet, so of course you can add/open these 3D layers with the SDK and provide an "indoor" experience. But utilizing ArcGIS Indoors will be a fair bit more dev effort for now.

 

Thanks

Mike

0 Kudos