Export textured mesh or point cloud of the scanned sapce from MagicLeap2

A MagicLeap beginner user here.

I want to export the scanned space from the local spaces. I could export the spatial map using ADB shell:
adb shell mlmapping -export_space “map name” but it only exports a *.map file.
How can I export the textured mesh as an *.obj or any other known format?

Also doing so using Unity SDK is fine.

MagicLeap Hub version: 2.0.14
sdk: v1.4.0-dev1
Version 1.3.0
Android API Level 29
Host OS: macOS

UPDATE: A raw mesh is also fine not necessarily textured.

1 Like

Hi @shayan,

We do not have anything out of the box that will do this at the moment. If you use Unity, though, you can use AssetDatabase.CreateAsset with your mesh, and then save it with AssetDatabase.SaveAssets();

Let me know if this helps.

Best,

El

1 Like

@kbabilinski You suggested exporting the scanned space as a .glb file (Refer to this thread Saving spatial anchors and using on another app - General - Magic Leap 2 Developer Forums)

But I don't have any options in the Spaces app to export anything, I just see option to rename, delete and scan a new space. Do you know how I can get the export option?

So, the only way I could download the scan was using the ADB commands on the Bash which gives me a .map and json file. I am not able to decode these files into a mesh. Can you please help me with a way around this problem?