MeshLib C Docs
Loading...
Searching...
No Matches
MRPartMapping.h
Go to the documentation of this file.
1#pragma once
2
3#include <MRCMisc/exports.h>
4
5#include <stddef.h>
6
7#ifdef __cplusplus
8extern "C" {
9#endif
10
11typedef struct MR_MapOrHashMap_MR_FaceId_MR_FaceId MR_MapOrHashMap_MR_FaceId_MR_FaceId; // Defined in `#include <MRCMesh/MRMapOrHashMap.h>`.
12typedef struct MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId; // Defined in `#include <MRCMesh/MRMapOrHashMap.h>`.
13typedef struct MR_MapOrHashMap_MR_VertId_MR_VertId MR_MapOrHashMap_MR_VertId_MR_VertId; // Defined in `#include <MRCMesh/MRMapOrHashMap.h>`.
14
15
20
21// source.id -> target.id
22// each map here can be either dense vector or hash map, the type is set by the user and preserved by mesh copying functions;
23// dense maps are better by speed and memory when source mesh is packed and must be copied entirely;
24// hash maps minimize memory consumption when only a small portion of source mesh is copied
30
31// source.id -> target.id
32// each map here can be either dense vector or hash map, the type is set by the user and preserved by mesh copying functions;
33// dense maps are better by speed and memory when source mesh is packed and must be copied entirely;
34// hash maps minimize memory consumption when only a small portion of source mesh is copied
40
41// source.id -> target.id
42// each map here can be either dense vector or hash map, the type is set by the user and preserved by mesh copying functions;
43// dense maps are better by speed and memory when source mesh is packed and must be copied entirely;
44// hash maps minimize memory consumption when only a small portion of source mesh is copied
50
56
62
68
74
80
86
87// target.id -> source.id
88// dense vectors are better by speed and memory when target mesh was empty before copying
94
95// target.id -> source.id
96// dense vectors are better by speed and memory when target mesh was empty before copying
102
103// target.id -> source.id
104// dense vectors are better by speed and memory when target mesh was empty before copying
110
116
122
128
134
140
146
150
155
166
169MRC_API const MR_PartMapping *MR_PartMapping_OffsetPtr(const MR_PartMapping *ptr, ptrdiff_t i);
170
174
180
182MRC_API void MR_PartMapping_Destroy(const MR_PartMapping *_this);
183
186
194
199
200#ifdef __cplusplus
201} // extern "C"
202#endif
struct MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId
Definition MRMapEdge.h:10
struct MR_MapOrHashMap_MR_FaceId_MR_FaceId MR_MapOrHashMap_MR_FaceId_MR_FaceId
Definition MRMapOrHashMap.h:35
struct MR_MapOrHashMap_MR_VertId_MR_VertId MR_MapOrHashMap_MR_VertId_MR_VertId
Definition MRMapOrHashMap.h:42
struct MR_PartMapping MR_PartMapping
Definition MRMesh.h:31
MRC_API void MR_PartMapping_Destroy(const MR_PartMapping *_this)
Destroys a heap-allocated instance of MR_PartMapping. Does nothing if the pointer is null.
MRC_API void MR_PartMapping_Set_src2tgtFaces(MR_PartMapping *_this, MR_MapOrHashMap_MR_FaceId_MR_FaceId *value)
MRC_API MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId ** MR_PartMapping_GetMutable_src2tgtEdges(MR_PartMapping *_this)
MRC_API MR_PartMapping * MR_PartMapping_ConstructFromAnother(const MR_PartMapping *_other)
MRC_API MR_MapOrHashMap_MR_FaceId_MR_FaceId ** MR_PartMapping_GetMutable_src2tgtFaces(MR_PartMapping *_this)
MRC_API void MR_PartMapping_Set_src2tgtEdges(MR_PartMapping *_this, MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId *value)
MRC_API void MR_PartMapping_Set_tgt2srcFaces(MR_PartMapping *_this, MR_MapOrHashMap_MR_FaceId_MR_FaceId *value)
MRC_API MR_PartMapping * MR_PartMapping_DefaultConstruct(void)
MRC_API MR_MapOrHashMap_MR_FaceId_MR_FaceId ** MR_PartMapping_GetMutable_tgt2srcFaces(MR_PartMapping *_this)
MRC_API MR_MapOrHashMap_MR_VertId_MR_VertId *const * MR_PartMapping_Get_src2tgtVerts(const MR_PartMapping *_this)
MRC_API MR_MapOrHashMap_MR_VertId_MR_VertId ** MR_PartMapping_GetMutable_tgt2srcVerts(MR_PartMapping *_this)
MRC_API MR_PartMapping * MR_PartMapping_AssignFromAnother(MR_PartMapping *_this, const MR_PartMapping *_other)
MRC_API MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId *const * MR_PartMapping_Get_tgt2srcEdges(const MR_PartMapping *_this)
MRC_API void MR_PartMapping_DestroyArray(const MR_PartMapping *_this)
Destroys a heap-allocated array of MR_PartMapping. Does nothing if the pointer is null.
MRC_API MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId *const * MR_PartMapping_Get_src2tgtEdges(const MR_PartMapping *_this)
MRC_API void MR_PartMapping_Set_tgt2srcVerts(MR_PartMapping *_this, MR_MapOrHashMap_MR_VertId_MR_VertId *value)
MRC_API MR_PartMapping * MR_PartMapping_DefaultConstructArray(size_t num_elems)
MRC_API void MR_PartMapping_clear(MR_PartMapping *_this)
MRC_API void MR_PartMapping_Set_src2tgtVerts(MR_PartMapping *_this, MR_MapOrHashMap_MR_VertId_MR_VertId *value)
MRC_API const MR_PartMapping * MR_PartMapping_OffsetPtr(const MR_PartMapping *ptr, ptrdiff_t i)
MRC_API MR_MapOrHashMap_MR_FaceId_MR_FaceId *const * MR_PartMapping_Get_src2tgtFaces(const MR_PartMapping *_this)
MRC_API MR_PartMapping * MR_PartMapping_OffsetMutablePtr(MR_PartMapping *ptr, ptrdiff_t i)
MRC_API MR_PartMapping * MR_PartMapping_ConstructFrom(MR_MapOrHashMap_MR_FaceId_MR_FaceId *src2tgtFaces, MR_MapOrHashMap_MR_VertId_MR_VertId *src2tgtVerts, MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId *src2tgtEdges, MR_MapOrHashMap_MR_FaceId_MR_FaceId *tgt2srcFaces, MR_MapOrHashMap_MR_VertId_MR_VertId *tgt2srcVerts, MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId *tgt2srcEdges)
MRC_API MR_MapOrHashMap_MR_VertId_MR_VertId ** MR_PartMapping_GetMutable_src2tgtVerts(MR_PartMapping *_this)
MRC_API MR_MapOrHashMap_MR_VertId_MR_VertId *const * MR_PartMapping_Get_tgt2srcVerts(const MR_PartMapping *_this)
MRC_API MR_MapOrHashMap_MR_FaceId_MR_FaceId *const * MR_PartMapping_Get_tgt2srcFaces(const MR_PartMapping *_this)
MRC_API void MR_PartMapping_Set_tgt2srcEdges(MR_PartMapping *_this, MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId *value)
MRC_API MR_MapOrHashMap_MR_UndirectedEdgeId_MR_EdgeId ** MR_PartMapping_GetMutable_tgt2srcEdges(MR_PartMapping *_this)