MeshLib C Docs
Loading...
Searching...
No Matches
MRUnionFind.h
Go to the documentation of this file.
1#pragma once
2
3#include <MRCMesh/MRId.h>
4#include <MRCMisc/common.h>
5#include <MRCMisc/exports.h>
6
7#include <stdbool.h>
8#include <stddef.h>
9#include <stdint.h>
10
11#ifdef __cplusplus
12extern "C" {
13#endif
14
15typedef struct MR_FaceMap MR_FaceMap; // Defined in `#include <MRCMesh/MRVector.h>`.
16typedef struct MR_UndirectedEdgeMap MR_UndirectedEdgeMap; // Defined in `#include <MRCMesh/MRVector.h>`.
17typedef struct MR_VertMap MR_VertMap; // Defined in `#include <MRCMesh/MRVector.h>`.
18typedef struct MR_std_pair_MR_FaceId_bool MR_std_pair_MR_FaceId_bool; // Defined in `#include <MRCMisc/std_pair_MR_FaceId_bool.h>`.
19typedef struct MR_std_pair_MR_UndirectedEdgeId_bool MR_std_pair_MR_UndirectedEdgeId_bool; // Defined in `#include <MRCMisc/std_pair_MR_UndirectedEdgeId_bool.h>`.
20typedef struct MR_std_pair_MR_VertId_bool MR_std_pair_MR_VertId_bool; // Defined in `#include <MRCMisc/std_pair_MR_VertId_bool.h>`.
21
22
33
44
55
59
64
67
70
74
79
82
85
90
95
100
107
112
117
122
127
132
138
144
149
153
158
161
164
168
173
176
179
184
189
194
201
206
211
216
221
226
232
238
243
247
252
255
258
262
267
270
273
278
283
288
295
300
305
310
315
320
326
332
337
338#ifdef __cplusplus
339} // extern "C"
340#endif
struct MR_VertMap MR_VertMap
Definition MRBitSet.h:41
struct MR_UndirectedEdgeMap MR_UndirectedEdgeMap
Definition MRBitSet.h:31
struct MR_FaceMap MR_FaceMap
Definition MRBitSet.h:27
struct MR_UnionFind_MR_FaceId MR_UnionFind_MR_FaceId
Definition MRMeshComponents.h:22
struct MR_UnionFind_MR_VertId MR_UnionFind_MR_VertId
Definition MRMeshComponents.h:24
struct MR_UnionFind_MR_UndirectedEdgeId MR_UnionFind_MR_UndirectedEdgeId
Definition MRMeshComponents.h:23
struct MR_std_pair_MR_FaceId_bool MR_std_pair_MR_FaceId_bool
Definition MRUnionFind.h:18
MRC_API bool MR_UnionFind_MR_UndirectedEdgeId_isRoot(const MR_UnionFind_MR_UndirectedEdgeId *_this, MR_UndirectedEdgeId a)
MRC_API MR_UnionFind_MR_VertId * MR_UnionFind_MR_VertId_ConstructFromAnother(MR_PassBy _other_pass_by, MR_UnionFind_MR_VertId *_other)
MRC_API const MR_UndirectedEdgeMap * MR_UnionFind_MR_UndirectedEdgeId_parents(const MR_UnionFind_MR_UndirectedEdgeId *_this)
MRC_API MR_UnionFind_MR_UndirectedEdgeId * MR_UnionFind_MR_UndirectedEdgeId_Construct(MR_uint64_t size)
MRC_API MR_VertId MR_UnionFind_MR_VertId_find(MR_UnionFind_MR_VertId *_this, MR_VertId a)
MRC_API MR_std_pair_MR_VertId_bool * MR_UnionFind_MR_VertId_unite(MR_UnionFind_MR_VertId *_this, MR_VertId first, MR_VertId second)
MRC_API MR_UndirectedEdgeId MR_UnionFind_MR_UndirectedEdgeId_parent(const MR_UnionFind_MR_UndirectedEdgeId *_this, MR_UndirectedEdgeId a)
MRC_API void MR_UnionFind_MR_FaceId_Destroy(const MR_UnionFind_MR_FaceId *_this)
Destroys a heap-allocated instance of MR_UnionFind_MR_FaceId. Does nothing if the pointer is null.
MRC_API void MR_UnionFind_MR_VertId_Destroy(const MR_UnionFind_MR_VertId *_this)
Destroys a heap-allocated instance of MR_UnionFind_MR_VertId. Does nothing if the pointer is null.
MRC_API MR_UndirectedEdgeId MR_UnionFind_MR_UndirectedEdgeId_find(MR_UnionFind_MR_UndirectedEdgeId *_this, MR_UndirectedEdgeId a)
MRC_API void MR_UnionFind_MR_FaceId_reset(MR_UnionFind_MR_FaceId *_this, MR_uint64_t size)
MRC_API MR_UndirectedEdgeId MR_UnionFind_MR_UndirectedEdgeId_findUpdateRange(MR_UnionFind_MR_UndirectedEdgeId *_this, MR_UndirectedEdgeId a, MR_UndirectedEdgeId begin, MR_UndirectedEdgeId end)
MRC_API MR_UnionFind_MR_UndirectedEdgeId * MR_UnionFind_MR_UndirectedEdgeId_AssignFromAnother(MR_UnionFind_MR_UndirectedEdgeId *_this, MR_PassBy _other_pass_by, MR_UnionFind_MR_UndirectedEdgeId *_other)
MRC_API MR_UnionFind_MR_VertId * MR_UnionFind_MR_VertId_AssignFromAnother(MR_UnionFind_MR_VertId *_this, MR_PassBy _other_pass_by, MR_UnionFind_MR_VertId *_other)
MRC_API void MR_UnionFind_MR_VertId_reset(MR_UnionFind_MR_VertId *_this, MR_uint64_t size)
MRC_API MR_std_pair_MR_FaceId_bool * MR_UnionFind_MR_FaceId_unite(MR_UnionFind_MR_FaceId *_this, MR_FaceId first, MR_FaceId second)
MRC_API bool MR_UnionFind_MR_FaceId_united(MR_UnionFind_MR_FaceId *_this, MR_FaceId first, MR_FaceId second)
struct MR_std_pair_MR_UndirectedEdgeId_bool MR_std_pair_MR_UndirectedEdgeId_bool
Definition MRUnionFind.h:19
MRC_API void MR_UnionFind_MR_UndirectedEdgeId_DestroyArray(const MR_UnionFind_MR_UndirectedEdgeId *_this)
Destroys a heap-allocated array of MR_UnionFind_MR_UndirectedEdgeId. Does nothing if the pointer is n...
MRC_API MR_UnionFind_MR_UndirectedEdgeId * MR_UnionFind_MR_UndirectedEdgeId_DefaultConstruct(void)
MRC_API bool MR_UnionFind_MR_UndirectedEdgeId_united(MR_UnionFind_MR_UndirectedEdgeId *_this, MR_UndirectedEdgeId first, MR_UndirectedEdgeId second)
MRC_API MR_UnionFind_MR_FaceId * MR_UnionFind_MR_FaceId_DefaultConstruct(void)
MRC_API MR_std_pair_MR_UndirectedEdgeId_bool * MR_UnionFind_MR_UndirectedEdgeId_unite(MR_UnionFind_MR_UndirectedEdgeId *_this, MR_UndirectedEdgeId first, MR_UndirectedEdgeId second)
MRC_API MR_UnionFind_MR_FaceId * MR_UnionFind_MR_FaceId_DefaultConstructArray(size_t num_elems)
MRC_API const MR_UnionFind_MR_UndirectedEdgeId * MR_UnionFind_MR_UndirectedEdgeId_OffsetPtr(const MR_UnionFind_MR_UndirectedEdgeId *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API MR_UnionFind_MR_FaceId * MR_UnionFind_MR_FaceId_OffsetMutablePtr(MR_UnionFind_MR_FaceId *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API bool MR_UnionFind_MR_FaceId_isRoot(const MR_UnionFind_MR_FaceId *_this, MR_FaceId a)
MRC_API void MR_UnionFind_MR_UndirectedEdgeId_reset(MR_UnionFind_MR_UndirectedEdgeId *_this, MR_uint64_t size)
MRC_API MR_UnionFind_MR_FaceId * MR_UnionFind_MR_FaceId_Construct(MR_uint64_t size)
MRC_API MR_UnionFind_MR_FaceId * MR_UnionFind_MR_FaceId_AssignFromAnother(MR_UnionFind_MR_FaceId *_this, MR_PassBy _other_pass_by, MR_UnionFind_MR_FaceId *_other)
MRC_API MR_UnionFind_MR_UndirectedEdgeId * MR_UnionFind_MR_UndirectedEdgeId_DefaultConstructArray(size_t num_elems)
MRC_API MR_UnionFind_MR_VertId * MR_UnionFind_MR_VertId_Construct(MR_uint64_t size)
MRC_API void MR_UnionFind_MR_FaceId_DestroyArray(const MR_UnionFind_MR_FaceId *_this)
Destroys a heap-allocated array of MR_UnionFind_MR_FaceId. Does nothing if the pointer is null.
MRC_API MR_UnionFind_MR_UndirectedEdgeId * MR_UnionFind_MR_UndirectedEdgeId_OffsetMutablePtr(MR_UnionFind_MR_UndirectedEdgeId *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API MR_uint64_t MR_UnionFind_MR_VertId_size(const MR_UnionFind_MR_VertId *_this)
MRC_API MR_VertId MR_UnionFind_MR_VertId_parent(const MR_UnionFind_MR_VertId *_this, MR_VertId a)
MRC_API MR_VertId MR_UnionFind_MR_VertId_findUpdateRange(MR_UnionFind_MR_VertId *_this, MR_VertId a, MR_VertId begin, MR_VertId end)
MRC_API const MR_VertMap * MR_UnionFind_MR_VertId_roots(MR_UnionFind_MR_VertId *_this)
struct MR_std_pair_MR_VertId_bool MR_std_pair_MR_VertId_bool
Definition MRUnionFind.h:20
MRC_API MR_FaceId MR_UnionFind_MR_FaceId_parent(const MR_UnionFind_MR_FaceId *_this, MR_FaceId a)
MRC_API void MR_UnionFind_MR_UndirectedEdgeId_Destroy(const MR_UnionFind_MR_UndirectedEdgeId *_this)
Destroys a heap-allocated instance of MR_UnionFind_MR_UndirectedEdgeId. Does nothing if the pointer i...
MRC_API int32_t MR_UnionFind_MR_FaceId_sizeOfComp(MR_UnionFind_MR_FaceId *_this, MR_FaceId a)
MRC_API MR_UnionFind_MR_UndirectedEdgeId * MR_UnionFind_MR_UndirectedEdgeId_ConstructFromAnother(MR_PassBy _other_pass_by, MR_UnionFind_MR_UndirectedEdgeId *_other)
MRC_API MR_UnionFind_MR_VertId * MR_UnionFind_MR_VertId_DefaultConstruct(void)
MRC_API MR_UnionFind_MR_VertId * MR_UnionFind_MR_VertId_DefaultConstructArray(size_t num_elems)
MRC_API MR_uint64_t MR_UnionFind_MR_FaceId_size(const MR_UnionFind_MR_FaceId *_this)
MRC_API MR_UnionFind_MR_VertId * MR_UnionFind_MR_VertId_OffsetMutablePtr(MR_UnionFind_MR_VertId *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API void MR_UnionFind_MR_VertId_DestroyArray(const MR_UnionFind_MR_VertId *_this)
Destroys a heap-allocated array of MR_UnionFind_MR_VertId. Does nothing if the pointer is null.
MRC_API MR_uint64_t MR_UnionFind_MR_UndirectedEdgeId_size(const MR_UnionFind_MR_UndirectedEdgeId *_this)
MRC_API int32_t MR_UnionFind_MR_VertId_sizeOfComp(MR_UnionFind_MR_VertId *_this, MR_VertId a)
MRC_API const MR_FaceMap * MR_UnionFind_MR_FaceId_roots(MR_UnionFind_MR_FaceId *_this)
MRC_API int32_t MR_UnionFind_MR_UndirectedEdgeId_sizeOfComp(MR_UnionFind_MR_UndirectedEdgeId *_this, MR_UndirectedEdgeId a)
MRC_API MR_FaceId MR_UnionFind_MR_FaceId_findUpdateRange(MR_UnionFind_MR_FaceId *_this, MR_FaceId a, MR_FaceId begin, MR_FaceId end)
MRC_API MR_FaceId MR_UnionFind_MR_FaceId_find(MR_UnionFind_MR_FaceId *_this, MR_FaceId a)
MRC_API const MR_FaceMap * MR_UnionFind_MR_FaceId_parents(const MR_UnionFind_MR_FaceId *_this)
MRC_API MR_UnionFind_MR_FaceId * MR_UnionFind_MR_FaceId_ConstructFromAnother(MR_PassBy _other_pass_by, MR_UnionFind_MR_FaceId *_other)
MRC_API const MR_VertMap * MR_UnionFind_MR_VertId_parents(const MR_UnionFind_MR_VertId *_this)
MRC_API const MR_UnionFind_MR_VertId * MR_UnionFind_MR_VertId_OffsetPtr(const MR_UnionFind_MR_VertId *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API bool MR_UnionFind_MR_VertId_isRoot(const MR_UnionFind_MR_VertId *_this, MR_VertId a)
MRC_API bool MR_UnionFind_MR_VertId_united(MR_UnionFind_MR_VertId *_this, MR_VertId first, MR_VertId second)
MRC_API const MR_UndirectedEdgeMap * MR_UnionFind_MR_UndirectedEdgeId_roots(MR_UnionFind_MR_UndirectedEdgeId *_this)
MRC_API const MR_UnionFind_MR_FaceId * MR_UnionFind_MR_FaceId_OffsetPtr(const MR_UnionFind_MR_FaceId *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MR_PassBy
Definition common.h:19
uint64_t MR_uint64_t
Definition common.h:14
#define MRC_API
Definition exports.h:11
size_t size() const
Definition MRId.h:46
Definition MRId.h:36
Definition MRId.h:56