# Where is the mesh saved after scanned (?)

**URL:** <https://community.nianticspatial.com/t/where-is-the-mesh-saved-after-scanned/3445>\
**Category:** I'm Stuck\
**Created:** [April 8, 2023, 9:02am UTC](https://community.nianticspatial.com/t/where-is-the-mesh-saved-after-scanned/3445 "2023-04-08T09:02:08Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![ina](https://sea2.discourse-cdn.com/niantic/user_avatar/community.nianticspatial.com/ina/32/1590_2.png) [@ina](https://community.nianticspatial.com/u/ina)\
**Post date:** [April 8, 2023, 9:02am UTC](https://community.nianticspatial.com/t/where-is-the-mesh-saved-after-scanned/3445/1 "2023-04-08T09:02:08Z")

</div>

In the scanning example, where is the mesh saved, and in what format? (Is there further documentation on the specifics here?)

---

<div class="post-metadata">

**Author:** ![Summer\_Gu](https://avatars.discourse-cdn.com/v4/letter/s/ed8c4c/32.png) [@Summer\_Gu](https://community.nianticspatial.com/u/Summer_Gu)\
**Post date:** [April 9, 2023, 3:12am UTC](https://community.nianticspatial.com/t/where-is-the-mesh-saved-after-scanned/3445/2 "2023-04-09T03:12:49Z")

</div>

Hi,

Here’s the detailed documentation: [Getting Started with the Scanning Framework — Niantic Lightship Augmented Reality Developer Kit release-2.5.1 documentation](https://lightship.dev/docs/ardk/scanning/getting_started.html)

Specifically, step 4 has the information to handle processed scan mesh results. Please let me know if you have further questions.

---

<div class="post-metadata">

**Author:** ![shoib](https://avatars.discourse-cdn.com/v4/letter/s/ccd318/32.png) [@shoib](https://community.nianticspatial.com/u/shoib)\
**Post date:** [April 11, 2023, 9:30am UTC](https://community.nianticspatial.com/t/where-is-the-mesh-saved-after-scanned/3445/3 "2023-04-11T09:30:44Z")

</div>

im stuck at step 4 at the start method where \_scanManager.OnScanResult += ScanResultHandler; is showing an error at OnScanResult

This is my code  
using Niantic.ARDK.AR;  
using Niantic.ARDK.AR.Scanning;  
using Niantic.ARDK.Extensions;  
using Niantic.ARDK.Extensions.Scanning;  
using UnityEngine;  
using UnityEngine.Events;  
using System.Collections;  
using UnityEngine.UI;  
using System;  
using System.Collections.Generic;

public class ScanningExampleManager : MonoBehaviour  
{  
[SerializeField]  
[Tooltip(“The scene’s ARScanManager”)]  
private ARScanManager \_scanManager;  
// …

```
[SerializeField]
private PointCloudVisualizer _pointCloudVisualizer;

void Start()
{
    // Set default visualizer
    _scanManager.SetVisualizer(_pointCloudVisualizer);
    _scanManager.OnScanResult += ScanResultHandler;

}

public void ScanButtonPressed()
{
    _scanManager.StartScanning();
}

public void StopButtonPressed()
{
    _scanManager.StopScanning();
}

public void ProcessButtonPressed()
{
    IScanner.State state = _scanManager.ScannerState;
    if (state == IScanner.State.ScanCompleted)
    {
        // Start processing scan 
        _scanManager.StartProcessing();
    }
}

public Slider _progressBar;

private void Update()
{
    IScanner.State state = _scanManager.ScannerState;

    if (state == IScanner.State.Processing)
    {
        _progressBar.gameObject.SetActive(true);
        _progressBar.value = _scanManager.GetScanProgress();
    }
    else
    {
        _progressBar.gameObject.SetActive(false);
    }
}

public void CancelProcessButtonPressed()
{
    _scanManager.CancelProcessing();
}

private GameObject scannedObject;
private GameObject _scannedObjectPrefab;
public Transform _scannedObjectParent;

private void ScanResultHandler(TexturedMesh texturedMesh, IScanner.State state, Vector3 centerPosition)
{
    if (texturedMesh != null)
    {
        if (scannedObject == null)
        {
            scannedObject = Instantiate(_scannedObjectPrefab, _scannedObjectParent);
        }
        Bounds meshBoundary = texturedMesh.mesh.bounds;
        scannedObject.transform.localPosition = -1 * meshBoundary.center;
        scannedObject.transform.localScale = Vector3.one / meshBoundary.extents.magnitude;
        scannedObject.GetComponent<MeshFilter>().sharedMesh = texturedMesh.mesh;
        if (texturedMesh.texture != null)
            scannedObject.GetComponent<Renderer>().material.mainTexture = texturedMesh.texture;
    }
}

```

}

---

<div class="post-metadata">

**Author:** ![Jesus\_Niantic](https://avatars.discourse-cdn.com/v4/letter/j/b782af/32.png) [@Jesus\_Niantic](https://community.nianticspatial.com/u/Jesus_Niantic)\
**Post date:** [April 11, 2023, 6:19pm UTC](https://community.nianticspatial.com/t/where-is-the-mesh-saved-after-scanned/3445/4 "2023-04-11T18:19:29Z")

</div>

Hello Shoib,

Sorry for the confusion, that event has been replaced with **ScanProcessed** (you can find it in the C# script the the ARScanManager) so instead of **\_scanManager.OnScanResult += ScanResultHandler** , you will want to do **\_scanManager.ScanProcessed += ScanResultHandler**

The arguments are also a little different so in your ScanResultHandler function, the signature should look like **private void ScanResultHandler(IScanner.ScanProcessedArgs args)** and \*\*args \*\*will contain the TexturedMesh.

If you have any additional questions, please open a separate topic and provide descriptions of your issues so that we can look into them.

---

<div class="post-metadata">

**Author:** ![Maverick\_Niantic](https://avatars.discourse-cdn.com/v4/letter/m/8edcca/32.png) [@Maverick\_Niantic](https://community.nianticspatial.com/u/Maverick_Niantic)\
**Post date:** [March 5, 2026, 11:44pm UTC](https://community.nianticspatial.com/t/where-is-the-mesh-saved-after-scanned/3445/5 "2026-03-05T23:44:51Z")

</div>

Age
