Functions | |
MRMESH_API Expected< Json::Value > | MR::deserializeJsonValue (std::istream &in) |
MRMESH_API Expected< Json::Value > | MR::deserializeJsonValue (const std::string &str) |
MRMESH_API Expected< Json::Value > | MR::deserializeJsonValue (const std::filesystem::path &path) |
MRMESH_API Expected< void > | MR::serializeMesh (const Mesh &mesh, const std::filesystem::path &path, const FaceBitSet *selection=nullptr, const char *saveMeshFormat=".mrmesh") |
MRMESH_API void | MR::serializeToJson (const Vector2i &vec, Json::Value &root) |
saves an object into json value | |
MRMESH_API void | MR::serializeToJson (const Vector2f &vec, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Vector3i &vec, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Vector3f &vec, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Vector4f &vec, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Box3i &box, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Box3f &box, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Color &col, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Matrix2f &matrix, Json::Value &root, bool skipIdentity=true) |
MRMESH_API void | MR::serializeToJson (const Matrix3f &matrix, Json::Value &root, bool skipIdentity=true) |
MRMESH_API void | MR::serializeToJson (const AffineXf2f &xf, Json::Value &root, bool skipIdentity=true) |
MRMESH_API void | MR::serializeToJson (const AffineXf3f &xf, Json::Value &root, bool skipIdentity=true) |
MRMESH_API void | MR::serializeToJson (const BitSet &bitset, Json::Value &root) |
MRMESH_API Expected< void > | MR::serializeToJson (const Mesh &mesh, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const Plane3f &plane, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const TriPointf &tp, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const MeshTexture &texture, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const std::vector< TextureId > &texturePerFace, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const std::vector< UVCoord > &uvCoords, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const std::vector< Color > &colors, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const MeshTriPoint &mtp, const MeshTopology &topology, Json::Value &root) |
MRMESH_API void | MR::serializeToJson (const PointOnFace &pf, Json::Value &root) |
MRMESH_API void | MR::serializeViaVerticesToJson (const UndirectedEdgeBitSet &edges, const MeshTopology &topology, Json::Value &root) |
MRMESH_API void | MR::deserializeViaVerticesFromJson (const Json::Value &root, UndirectedEdgeBitSet &edges, const MeshTopology &topology) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Vector2i &vec) |
loads an object from json value | |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Vector2f &vec) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Vector3i &vec) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Vector3f &vec) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Vector4f &vec) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Color &col) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Matrix2f &matrix) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Matrix3f &matrix) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, AffineXf2f &xf) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, AffineXf3f &xf) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, BitSet &bitset) |
MRMESH_API Expected< Mesh > | MR::deserializeFromJson (const Json::Value &root, VertColors *colors=nullptr) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, Plane3f &plane) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, TriPointf &tp) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, MeshTexture &texture) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, std::vector< TextureId > &texturePerFace) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, std::vector< UVCoord > &uvCoords) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, std::vector< Color > &colors) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, MeshTriPoint &mtp, const MeshTopology &topology) |
MRMESH_API void | MR::deserializeFromJson (const Json::Value &root, PointOnFace &pf) |
MRMESH_API Expected< void > | MR::decompressZip (const std::filesystem::path &zipFile, const std::filesystem::path &targetFolder, const char *password=nullptr) |
decompresses given zip-file into given folder | |
MRMESH_API Expected< void > | MR::decompressZip (std::istream &zipStream, const std::filesystem::path &targetFolder, const char *password=nullptr) |
decompresses given binary stream (containing the data of a zip file only) into given folder | |
MRMESH_API Expected< void > | MR::compressZip (const std::filesystem::path &zipFile, const std::filesystem::path &sourceFolder, const std::vector< std::filesystem::path > &excludeFiles={}, const char *password=nullptr, ProgressCallback cb={}) |
compresses given folder in given zip-file | |
MRMESH_API Expected< void > MR::compressZip | ( | const std::filesystem::path & | zipFile, |
const std::filesystem::path & | sourceFolder, | ||
const std::vector< std::filesystem::path > & | excludeFiles = {}, | ||
const char * | password = nullptr, | ||
ProgressCallback | cb = {} ) |
compresses given folder in given zip-file
excludeFiles | files that should not be included to result zip |
password | if password is given then the archive will be encrypted |
cb | an option to get progress notifications and cancel the operation |
MRMESH_API Expected< void > MR::decompressZip | ( | const std::filesystem::path & | zipFile, |
const std::filesystem::path & | targetFolder, | ||
const char * | password = nullptr ) |
decompresses given zip-file into given folder
password | if password is given then it will be used to decipher encrypted archive |
MRMESH_API Expected< void > MR::decompressZip | ( | std::istream & | zipStream, |
const std::filesystem::path & | targetFolder, | ||
const char * | password = nullptr ) |
decompresses given binary stream (containing the data of a zip file only) into given folder
password | if password is given then it will be used to decipher encrypted archive |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
AffineXf2f & | xf ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
AffineXf3f & | xf ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
BitSet & | bitset ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Color & | col ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Matrix2f & | matrix ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Matrix3f & | matrix ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
MeshTexture & | texture ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
MeshTriPoint & | mtp, | ||
const MeshTopology & | topology ) |
this version takes topology to construct MeshTriPoint from its representation relative a face; also beware that de-serialization will work only if faces are not renumbered (so please pack mesh before saving)
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Plane3f & | plane ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
PointOnFace & | pf ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
std::vector< Color > & | colors ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
std::vector< TextureId > & | texturePerFace ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
std::vector< UVCoord > & | uvCoords ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
TriPointf & | tp ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Vector2f & | vec ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Vector2i & | vec ) |
loads an object from json value
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Vector3f & | vec ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Vector3i & | vec ) |
MRMESH_API void MR::deserializeFromJson | ( | const Json::Value & | root, |
Vector4f & | vec ) |
MRMESH_API Expected< Mesh > MR::deserializeFromJson | ( | const Json::Value & | root, |
VertColors * | colors = nullptr ) |
MRMESH_API Expected< Json::Value > MR::deserializeJsonValue | ( | const std::filesystem::path & | path | ) |
MRMESH_API Expected< Json::Value > MR::deserializeJsonValue | ( | const std::string & | str | ) |
MRMESH_API Expected< Json::Value > MR::deserializeJsonValue | ( | std::istream & | in | ) |
MRMESH_API void MR::deserializeViaVerticesFromJson | ( | const Json::Value & | root, |
UndirectedEdgeBitSet & | edges, | ||
const MeshTopology & | topology ) |
MRMESH_API Expected< void > MR::serializeMesh | ( | const Mesh & | mesh, |
const std::filesystem::path & | path, | ||
const FaceBitSet * | selection = nullptr, | ||
const char * | saveMeshFormat = ".mrmesh" ) |
saves mesh with optional selection to mru format; this is very convenient for saving intermediate states during algorithm debugging; ".mrmesh" save mesh format is not space efficient, but guaranties no changes in the topology after loading
MRMESH_API void MR::serializeToJson | ( | const AffineXf2f & | xf, |
Json::Value & | root, | ||
bool | skipIdentity = true ) |
MRMESH_API void MR::serializeToJson | ( | const AffineXf3f & | xf, |
Json::Value & | root, | ||
bool | skipIdentity = true ) |
MRMESH_API void MR::serializeToJson | ( | const BitSet & | bitset, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Box3f & | box, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Box3i & | box, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Color & | col, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Matrix2f & | matrix, |
Json::Value & | root, | ||
bool | skipIdentity = true ) |
MRMESH_API void MR::serializeToJson | ( | const Matrix3f & | matrix, |
Json::Value & | root, | ||
bool | skipIdentity = true ) |
MRMESH_API Expected< void > MR::serializeToJson | ( | const Mesh & | mesh, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const MeshTexture & | texture, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const MeshTriPoint & | mtp, |
const MeshTopology & | topology, | ||
Json::Value & | root ) |
this version takes topology to convert MeshTriPoint in its representation relative a face; also beware that de-serialization will work only if faces are not renumbered (so please pack mesh before saving)
MRMESH_API void MR::serializeToJson | ( | const Plane3f & | plane, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const PointOnFace & | pf, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const std::vector< Color > & | colors, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const std::vector< TextureId > & | texturePerFace, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const std::vector< UVCoord > & | uvCoords, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const TriPointf & | tp, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Vector2f & | vec, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Vector2i & | vec, |
Json::Value & | root ) |
saves an object into json value
MRMESH_API void MR::serializeToJson | ( | const Vector3f & | vec, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Vector3i & | vec, |
Json::Value & | root ) |
MRMESH_API void MR::serializeToJson | ( | const Vector4f & | vec, |
Json::Value & | root ) |
MRMESH_API void MR::serializeViaVerticesToJson | ( | const UndirectedEdgeBitSet & | edges, |
const MeshTopology & | topology, | ||
Json::Value & | root ) |
serialize given edges into json first converting them into pairs of vertices, which is safer when edge ids change after saving/loading, but vertex ids are not