blob: 4a5492487106a46c49afc2a6cfef37d6b413fd64 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
#ifndef BM_INLINE_C
#define BM_INLINE_C
#include "bmesh.h"
BM_INLINE int BM_TestHFlag(const void *element, const int flag)
{
return ((const BMHeader *)element)->flag & flag;
}
BM_INLINE void BM_SetHFlag(void *element, const int flag)
{
((BMHeader *)element)->flag |= flag;
}
BM_INLINE void BM_ClearHFlag(void *element, const int flag)
{
((BMHeader *)element)->flag &= ~flag;
}
BM_INLINE void BM_ToggleHFlag(void *element, const int flag)
{
((BMHeader *)element)->flag ^= flag;
}
BM_INLINE void BM_MergeHFlag(void *element_a, void *element_b)
{
((BMHeader *)element_a)->flag =
((BMHeader *)element_b)->flag = (((BMHeader *)element_a)->flag |
((BMHeader *)element_b)->flag);
}
BM_INLINE void BM_SetIndex(void *element, const int index)
{
((BMHeader *)element)->index = index;
}
BM_INLINE int BM_GetIndex(const void *element)
{
return ((BMHeader *)element)->index;
}
#endif /*BM_INLINE_C*/
|