public static void ExportModel(string filename)
        {
            ExportStage      = 0;
            ExportPercentage = 0;
            ExportError      = (int)Error.WORK;
            IsExportingMesh  = true;
            IsScannedMeshPreviewCompleted = false;

            SRWorkModule_API.SetReconstructionParameterBool((int)ReconstructionParam.EXPORT_ADAPTIVE_MODEL, ExportAdaptiveMesh);
            if (ExportAdaptiveMesh)
            {
                SRWorkModule_API.SetReconstructionParameterFloat((int)ReconstructionParam.ADAPTIVE_MAX_GRID, ExportAdaptiveMaxGridSize * 0.01f);   // cm to m
                SRWorkModule_API.SetReconstructionParameterFloat((int)ReconstructionParam.ADAPTIVE_MIN_GRID, ExportAdaptiveMinGridSize * 0.01f);
                SRWorkModule_API.SetReconstructionParameterFloat((int)ReconstructionParam.ADAPTIVE_ERROR_THRES, ExportAdaptiveErrorThres);
            }

            //if ((int)Error.WORK != SRWorkModule_API.RegisterReconstructionCallback(Marshal.GetFunctionPointerForDelegate((ExportProgressCallback)UpdateExportProgress)))
            //    Debug.Log("[ViveSR] [ExportModel] Progress listener failed to register");
            //ViveSR_Framework.RegisterCallback(ViveSR_Framework.MODULE_ID_RIGID_RECONSTRUCTION, (int)ReconstructionCallback.EXPORT_PROGRESS, Marshal.GetFunctionPointerForDelegate((ExportProgressCallback)UpdateExportProgress));

            byte[] bytearray = System.Text.Encoding.ASCII.GetBytes(filename);
            IntPtr parameter = Marshal.AllocCoTaskMem(filename.Length);

            Marshal.Copy(bytearray, 0, parameter, filename.Length);

            SRWorkModule_API.SetReconstructionOutputFileName(parameter, filename.Length);
        }