MeshLib
 
Loading...
Searching...
No Matches
MRViewerIO.h
Go to the documentation of this file.
1#pragma once
2
3#include "exports.h"
4#include "MRMesh/MRExpected.h"
6#include <filesystem>
7#include <cstring>
8
9namespace MR
10{
11class Object;
12
14{
15 // if true then before saving, original files is renamed, and renamed back if saving fails
16 bool backupOriginalFile = false;
17 // callback function to set progress (for progress bar)
19};
20
21
26MRVIEWER_API VoidOrErrStr saveObjectToFile( const Object& obj, const std::filesystem::path& filename,
27 const SaveObjectSettings & settings = {} );
28
29} //namespace MR
named object in the data model
Definition MRObject.h:60
std::function< bool(float)> ProgressCallback
Definition MRMesh/MRMeshFwd.h:589
Definition MRCameraOrientationPlugin.h:7
MRVIEWER_API VoidOrErrStr saveObjectToFile(const Object &obj, const std::filesystem::path &filename, const SaveObjectSettings &settings={})
save visual object (mesh, lines, points or voxels) to file
Expected< void > VoidOrErrStr
return type for a void function that can produce an error string
Definition MRExpected.h:60
Definition MRViewerIO.h:14
ProgressCallback callback
Definition MRViewerIO.h:18
bool backupOriginalFile
Definition MRViewerIO.h:16