Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-03-20 12:42:26 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-03-20 12:42:26 +0400
commit9dd0c4c232fcdd2e88a2f8ba9391017a8bd55ce3 (patch)
tree5b86231770d067735ebb61b2b5fe3c099b5ef089 /source
parenta0ea68a584a5d12bad08632f867e921ea781f3af (diff)
rename define BM_INLINE -> BLI_INLINE to avoid confusion with bmesh defines.
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/intern/DerivedMesh.c4
-rw-r--r--source/blender/blenkernel/intern/deform.c2
-rw-r--r--source/blender/blenkernel/intern/navmesh_conversion.c4
-rw-r--r--source/blender/blenlib/BLI_utildefines.h6
-rw-r--r--source/blender/blenlib/intern/voxel.c6
-rw-r--r--source/blender/bmesh/bmesh.h16
-rw-r--r--source/blender/bmesh/bmesh_operator_api.h10
-rw-r--r--source/blender/bmesh/intern/bmesh_core.c2
-rw-r--r--source/blender/bmesh/intern/bmesh_inline.c16
-rw-r--r--source/blender/bmesh/intern/bmesh_iterators_inline.c6
-rw-r--r--source/blender/bmesh/intern/bmesh_mesh_conv.c2
-rw-r--r--source/blender/bmesh/intern/bmesh_operator_api_inline.c26
-rw-r--r--source/blender/bmesh/operators/bmo_create.c4
-rw-r--r--source/blender/editors/sculpt_paint/paint_vertex.c24
-rw-r--r--source/blender/editors/space_text/text_ops.c2
-rw-r--r--source/blender/render/intern/source/volumetric.c2
16 files changed, 66 insertions, 66 deletions
diff --git a/source/blender/blenkernel/intern/DerivedMesh.c b/source/blender/blenkernel/intern/DerivedMesh.c
index bf3f461d3f5..68264ddd200 100644
--- a/source/blender/blenkernel/intern/DerivedMesh.c
+++ b/source/blender/blenkernel/intern/DerivedMesh.c
@@ -2854,12 +2854,12 @@ void DM_set_object_boundbox(Object *ob, DerivedMesh *dm)
*/
-BM_INLINE int navmesh_bit(int a, int b)
+BLI_INLINE int navmesh_bit(int a, int b)
{
return (a & (1 << b)) >> b;
}
-BM_INLINE void navmesh_intToCol(int i, float col[3])
+BLI_INLINE void navmesh_intToCol(int i, float col[3])
{
int r = navmesh_bit(i, 0) + navmesh_bit(i, 3) * 2 + 1;
int g = navmesh_bit(i, 1) + navmesh_bit(i, 4) * 2 + 1;
diff --git a/source/blender/blenkernel/intern/deform.c b/source/blender/blenkernel/intern/deform.c
index 6de24856ce8..186a4d41403 100644
--- a/source/blender/blenkernel/intern/deform.c
+++ b/source/blender/blenkernel/intern/deform.c
@@ -437,7 +437,7 @@ void defgroup_unique_name(bDeformGroup *dg, Object *ob)
BLI_uniquename_cb(defgroup_unique_check, &data, "Group", '.', dg->name, sizeof(dg->name));
}
-BM_INLINE int is_char_sep(const char c)
+BLI_INLINE int is_char_sep(const char c)
{
return ELEM4(c, '.', ' ', '-', '_');
}
diff --git a/source/blender/blenkernel/intern/navmesh_conversion.c b/source/blender/blenkernel/intern/navmesh_conversion.c
index cdba036a6ae..f14482c4cb3 100644
--- a/source/blender/blenkernel/intern/navmesh_conversion.c
+++ b/source/blender/blenkernel/intern/navmesh_conversion.c
@@ -44,12 +44,12 @@
#include "recast-capi.h"
-BM_INLINE float area2(const float* a, const float* b, const float* c)
+BLI_INLINE float area2(const float* a, const float* b, const float* c)
{
return (b[0] - a[0]) * (c[2] - a[2]) - (c[0] - a[0]) * (b[2] - a[2]);
}
-BM_INLINE int left(const float* a, const float* b, const float* c)
+BLI_INLINE int left(const float* a, const float* b, const float* c)
{
return area2(a, b, c) < 0;
}
diff --git a/source/blender/blenlib/BLI_utildefines.h b/source/blender/blenlib/BLI_utildefines.h
index 06de3ff05fc..d3f1d526317 100644
--- a/source/blender/blenlib/BLI_utildefines.h
+++ b/source/blender/blenlib/BLI_utildefines.h
@@ -251,12 +251,12 @@
/*little macro so inline keyword works*/
#if defined(_MSC_VER)
-# define BM_INLINE static __forceinline
+# define BLI_INLINE static __forceinline
#elif defined(__GNUC__)
-# define BM_INLINE static inline __attribute((always_inline))
+# define BLI_INLINE static inline __attribute((always_inline))
#else
/* #warning "MSC/GNUC defines not found, inline non-functional" */
-# define BM_INLINE static
+# define BLI_INLINE static
#endif
diff --git a/source/blender/blenlib/intern/voxel.c b/source/blender/blenlib/intern/voxel.c
index dd56988fd90..34862c724e1 100644
--- a/source/blender/blenlib/intern/voxel.c
+++ b/source/blender/blenlib/intern/voxel.c
@@ -35,7 +35,7 @@
-BM_INLINE float D(float *data, const int res[3], int x, int y, int z)
+BLI_INLINE float D(float *data, const int res[3], int x, int y, int z)
{
CLAMP(x, 0, res[0]-1);
CLAMP(y, 0, res[1]-1);
@@ -57,7 +57,7 @@ float voxel_sample_nearest(float *data, const int res[3], const float co[3])
}
// returns highest integer <= x as integer (slightly faster than floor())
-BM_INLINE int FLOORI(float x)
+BLI_INLINE int FLOORI(float x)
{
const int r = (int)x;
return ((x >= 0.f) || (float)r == x) ? r : (r - 1);
@@ -65,7 +65,7 @@ BM_INLINE int FLOORI(float x)
// clamp function, cannot use the CLAMPIS macro, it sometimes returns unwanted results apparently related to gcc optimization flag -fstrict-overflow which is enabled at -O2
// this causes the test (x + 2) < 0 with int x == 2147483647 to return false (x being an integer, x + 2 should wrap around to -2147483647 so the test < 0 should return true, which it doesn't)
-BM_INLINE int _clamp(int a, int b, int c)
+BLI_INLINE int _clamp(int a, int b, int c)
{
return (a < b) ? b : ((a > c) ? c : a);
}
diff --git a/source/blender/bmesh/bmesh.h b/source/blender/bmesh/bmesh.h
index 56efe88c104..0cb1f5c051a 100644
--- a/source/blender/bmesh/bmesh.h
+++ b/source/blender/bmesh/bmesh.h
@@ -219,12 +219,12 @@ extern "C" {
#define BM_elem_flag_toggle( ele, hflag) _bm_elem_flag_toggle (&(ele)->head, hflag)
#define BM_elem_flag_merge( ele_a, ele_b) _bm_elem_flag_merge (&(ele_a)->head, &(ele_b)->head)
-BM_INLINE char _bm_elem_flag_test(const BMHeader *head, const char hflag);
-BM_INLINE void _bm_elem_flag_enable(BMHeader *head, const char hflag);
-BM_INLINE void _bm_elem_flag_disable(BMHeader *head, const char hflag);
-BM_INLINE void _bm_elem_flag_set(BMHeader *head, const char hflag, const int val);
-BM_INLINE void _bm_elem_flag_toggle(BMHeader *head, const char hflag);
-BM_INLINE void _bm_elem_flag_merge(BMHeader *head_a, BMHeader *head_b);
+BLI_INLINE char _bm_elem_flag_test(const BMHeader *head, const char hflag);
+BLI_INLINE void _bm_elem_flag_enable(BMHeader *head, const char hflag);
+BLI_INLINE void _bm_elem_flag_disable(BMHeader *head, const char hflag);
+BLI_INLINE void _bm_elem_flag_set(BMHeader *head, const char hflag, const int val);
+BLI_INLINE void _bm_elem_flag_toggle(BMHeader *head, const char hflag);
+BLI_INLINE void _bm_elem_flag_merge(BMHeader *head_a, BMHeader *head_b);
/* notes on BM_elem_index_set(...) usage,
* Set index is sometimes abused as temp storage, other times we cant be
@@ -257,8 +257,8 @@ BM_INLINE void _bm_elem_flag_merge(BMHeader *head_a, BMHeader *head_b);
#define BM_elem_index_get(ele) _bm_elem_index_get(&(ele)->head)
#define BM_elem_index_set(ele, index) _bm_elem_index_set(&(ele)->head, index)
-BM_INLINE int _bm_elem_index_get(const BMHeader *ele);
-BM_INLINE void _bm_elem_index_set(BMHeader *ele, const int index);
+BLI_INLINE int _bm_elem_index_get(const BMHeader *ele);
+BLI_INLINE void _bm_elem_index_set(BMHeader *ele, const int index);
#ifdef USE_BMESH_HOLES
# define BM_FACE_FIRST_LOOP(p) (((BMLoopList *)((p)->loops.first))->first)
diff --git a/source/blender/bmesh/bmesh_operator_api.h b/source/blender/bmesh/bmesh_operator_api.h
index c53a76a59d6..84de5d57aa3 100644
--- a/source/blender/bmesh/bmesh_operator_api.h
+++ b/source/blender/bmesh/bmesh_operator_api.h
@@ -81,11 +81,11 @@ struct GHashIterator;
#define BMO_elem_flag_set( bm, ele, oflag, val) _bmo_elem_flag_set (bm, (ele)->oflags, oflag, val)
#define BMO_elem_flag_toggle( bm, ele, oflag) _bmo_elem_flag_toggle (bm, (ele)->oflags, oflag)
-BM_INLINE short _bmo_elem_flag_test(BMesh *bm, BMFlagLayer *oflags, const short oflag);
-BM_INLINE void _bmo_elem_flag_enable(BMesh *bm, BMFlagLayer *oflags, const short oflag);
-BM_INLINE void _bmo_elem_flag_disable(BMesh *bm, BMFlagLayer *oflags, const short oflag);
-BM_INLINE void _bmo_elem_flag_set(BMesh *bm, BMFlagLayer *oflags, const short oflag, int val);
-BM_INLINE void _bmo_elem_flag_toggle(BMesh *bm, BMFlagLayer *oflags, const short oflag);
+BLI_INLINE short _bmo_elem_flag_test(BMesh *bm, BMFlagLayer *oflags, const short oflag);
+BLI_INLINE void _bmo_elem_flag_enable(BMesh *bm, BMFlagLayer *oflags, const short oflag);
+BLI_INLINE void _bmo_elem_flag_disable(BMesh *bm, BMFlagLayer *oflags, const short oflag);
+BLI_INLINE void _bmo_elem_flag_set(BMesh *bm, BMFlagLayer *oflags, const short oflag, int val);
+BLI_INLINE void _bmo_elem_flag_toggle(BMesh *bm, BMFlagLayer *oflags, const short oflag);
/* slot type arrays are terminated by the last member
* having a slot type of 0.*/
diff --git a/source/blender/bmesh/intern/bmesh_core.c b/source/blender/bmesh/intern/bmesh_core.c
index c1814b0ae96..6aaa2911bd9 100644
--- a/source/blender/bmesh/intern/bmesh_core.c
+++ b/source/blender/bmesh/intern/bmesh_core.c
@@ -240,7 +240,7 @@ BMFace *BM_face_copy(BMesh *bm, BMFace *f, const short copyverts, const short co
* only create the face, since this calloc's the length is initialized to 0,
* leave adding loops to the caller.
*/
-BM_INLINE BMFace *bm_face_create__internal(BMesh *bm)
+BLI_INLINE BMFace *bm_face_create__internal(BMesh *bm)
{
BMFace *f;
diff --git a/source/blender/bmesh/intern/bmesh_inline.c b/source/blender/bmesh/intern/bmesh_inline.c
index f7a0fb5c45c..085488cf7ed 100644
--- a/source/blender/bmesh/intern/bmesh_inline.c
+++ b/source/blender/bmesh/intern/bmesh_inline.c
@@ -31,44 +31,44 @@
#include "bmesh.h"
-BM_INLINE char _bm_elem_flag_test(const BMHeader *head, const char hflag)
+BLI_INLINE char _bm_elem_flag_test(const BMHeader *head, const char hflag)
{
return head->hflag & hflag;
}
-BM_INLINE void _bm_elem_flag_enable(BMHeader *head, const char hflag)
+BLI_INLINE void _bm_elem_flag_enable(BMHeader *head, const char hflag)
{
head->hflag |= hflag;
}
-BM_INLINE void _bm_elem_flag_disable(BMHeader *head, const char hflag)
+BLI_INLINE void _bm_elem_flag_disable(BMHeader *head, const char hflag)
{
head->hflag &= ~hflag;
}
-BM_INLINE void _bm_elem_flag_set(BMHeader *head, const char hflag, const int val)
+BLI_INLINE void _bm_elem_flag_set(BMHeader *head, const char hflag, const int val)
{
if (val) _bm_elem_flag_enable(head, hflag);
else _bm_elem_flag_disable(head, hflag);
}
-BM_INLINE void _bm_elem_flag_toggle(BMHeader *head, const char hflag)
+BLI_INLINE void _bm_elem_flag_toggle(BMHeader *head, const char hflag)
{
head->hflag ^= hflag;
}
-BM_INLINE void _bm_elem_flag_merge(BMHeader *head_a, BMHeader *head_b)
+BLI_INLINE void _bm_elem_flag_merge(BMHeader *head_a, BMHeader *head_b)
{
head_a->hflag = head_b->hflag = head_a->hflag | head_b->hflag;
}
-BM_INLINE void _bm_elem_index_set(BMHeader *head, const int index)
+BLI_INLINE void _bm_elem_index_set(BMHeader *head, const int index)
{
head->index = index;
}
-BM_INLINE int _bm_elem_index_get(const BMHeader *head)
+BLI_INLINE int _bm_elem_index_get(const BMHeader *head)
{
return head->index;
}
diff --git a/source/blender/bmesh/intern/bmesh_iterators_inline.c b/source/blender/bmesh/intern/bmesh_iterators_inline.c
index ed65b0e7fac..bb16fcc439c 100644
--- a/source/blender/bmesh/intern/bmesh_iterators_inline.c
+++ b/source/blender/bmesh/intern/bmesh_iterators_inline.c
@@ -39,7 +39,7 @@
*
* Calls an iterators step fucntion to return the next element.
*/
-BM_INLINE void *BM_iter_step(BMIter *iter)
+BLI_INLINE void *BM_iter_step(BMIter *iter)
{
return iter->step(iter);
}
@@ -52,7 +52,7 @@ BM_INLINE void *BM_iter_step(BMIter *iter)
* it with the appropriate function pointers based
* upon its type.
*/
-BM_INLINE int BM_iter_init(BMIter *iter, BMesh *bm, const char itype, void *data)
+BLI_INLINE int BM_iter_init(BMIter *iter, BMesh *bm, const char itype, void *data)
{
/* int argtype; */
iter->itype = itype;
@@ -179,7 +179,7 @@ BM_INLINE int BM_iter_init(BMIter *iter, BMesh *bm, const char itype, void *data
* to return the first element of the iterator.
*
*/
-BM_INLINE void *BM_iter_new(BMIter *iter, BMesh *bm, const char itype, void *data)
+BLI_INLINE void *BM_iter_new(BMIter *iter, BMesh *bm, const char itype, void *data)
{
if (LIKELY(BM_iter_init(iter, bm, itype, data))) {
return BM_iter_step(iter);
diff --git a/source/blender/bmesh/intern/bmesh_mesh_conv.c b/source/blender/bmesh/intern/bmesh_mesh_conv.c
index b10e25a318c..476c049c687 100644
--- a/source/blender/bmesh/intern/bmesh_mesh_conv.c
+++ b/source/blender/bmesh/intern/bmesh_mesh_conv.c
@@ -407,7 +407,7 @@ static BMVert **bm_to_mesh_vertex_map(BMesh *bm, int ototvert)
return vertMap;
}
-BM_INLINE void bmesh_quick_edgedraw_flag(MEdge *med, BMEdge *e)
+BLI_INLINE void bmesh_quick_edgedraw_flag(MEdge *med, BMEdge *e)
{
/* this is a cheap way to set the edge draw, its not precise and will
* pick the first 2 faces an edge uses */
diff --git a/source/blender/bmesh/intern/bmesh_operator_api_inline.c b/source/blender/bmesh/intern/bmesh_operator_api_inline.c
index 5b88d9f1b96..91fc3b1e4ca 100644
--- a/source/blender/bmesh/intern/bmesh_operator_api_inline.c
+++ b/source/blender/bmesh/intern/bmesh_operator_api_inline.c
@@ -41,39 +41,39 @@
* ghash or a mapping slot to do it. */
/* flags 15 and 16 (1 << 14 and 1 << 15) are reserved for bmesh api use */
-BM_INLINE short _bmo_elem_flag_test(BMesh *bm, BMFlagLayer *oflags, const short oflag)
+BLI_INLINE short _bmo_elem_flag_test(BMesh *bm, BMFlagLayer *oflags, const short oflag)
{
return oflags[bm->stackdepth - 1].f & oflag;
}
-BM_INLINE void _bmo_elem_flag_enable(BMesh *bm, BMFlagLayer *oflags, const short oflag)
+BLI_INLINE void _bmo_elem_flag_enable(BMesh *bm, BMFlagLayer *oflags, const short oflag)
{
oflags[bm->stackdepth - 1].f |= oflag;
}
-BM_INLINE void _bmo_elem_flag_disable(BMesh *bm, BMFlagLayer *oflags, const short oflag)
+BLI_INLINE void _bmo_elem_flag_disable(BMesh *bm, BMFlagLayer *oflags, const short oflag)
{
oflags[bm->stackdepth - 1].f &= ~oflag;
}
-BM_INLINE void _bmo_elem_flag_set(BMesh *bm, BMFlagLayer *oflags, const short oflag, int val)
+BLI_INLINE void _bmo_elem_flag_set(BMesh *bm, BMFlagLayer *oflags, const short oflag, int val)
{
if (val) oflags[bm->stackdepth - 1].f |= oflag;
else oflags[bm->stackdepth - 1].f &= ~oflag;
}
-BM_INLINE void _bmo_elem_flag_toggle(BMesh *bm, BMFlagLayer *oflags, const short oflag)
+BLI_INLINE void _bmo_elem_flag_toggle(BMesh *bm, BMFlagLayer *oflags, const short oflag)
{
oflags[bm->stackdepth - 1].f ^= oflag;
}
-BM_INLINE void BMO_slot_map_int_insert(BMesh *bm, BMOperator *op, const char *slotname,
+BLI_INLINE void BMO_slot_map_int_insert(BMesh *bm, BMOperator *op, const char *slotname,
void *element, int val)
{
BMO_slot_map_insert(bm, op, slotname, element, &val, sizeof(int));
}
-BM_INLINE void BMO_slot_map_float_insert(BMesh *bm, BMOperator *op, const char *slotname,
+BLI_INLINE void BMO_slot_map_float_insert(BMesh *bm, BMOperator *op, const char *slotname,
void *element, float val)
{
BMO_slot_map_insert(bm, op, slotname, element, &val, sizeof(float));
@@ -85,13 +85,13 @@ BM_INLINE void BMO_slot_map_float_insert(BMesh *bm, BMOperator *op, const char *
* do NOT use these for non-operator-api-allocated memory! instead
* use BMO_slot_map_data_get and BMO_slot_map_insert, which copies the data. */
-BM_INLINE void BMO_slot_map_ptr_insert(BMesh *bm, BMOperator *op, const char *slotname,
+BLI_INLINE void BMO_slot_map_ptr_insert(BMesh *bm, BMOperator *op, const char *slotname,
void *element, void *val)
{
BMO_slot_map_insert(bm, op, slotname, element, &val, sizeof(void *));
}
-BM_INLINE int BMO_slot_map_contains(BMesh *UNUSED(bm), BMOperator *op, const char *slotname, void *element)
+BLI_INLINE int BMO_slot_map_contains(BMesh *UNUSED(bm), BMOperator *op, const char *slotname, void *element)
{
BMOpSlot *slot = BMO_slot_get(op, slotname);
BLI_assert(slot->slottype == BMO_OP_SLOT_MAPPING);
@@ -102,7 +102,7 @@ BM_INLINE int BMO_slot_map_contains(BMesh *UNUSED(bm), BMOperator *op, const cha
return BLI_ghash_haskey(slot->data.ghash, element);
}
-BM_INLINE void *BMO_slot_map_data_get(BMesh *UNUSED(bm), BMOperator *op, const char *slotname,
+BLI_INLINE void *BMO_slot_map_data_get(BMesh *UNUSED(bm), BMOperator *op, const char *slotname,
void *element)
{
BMOElemMapping *mapping;
@@ -119,7 +119,7 @@ BM_INLINE void *BMO_slot_map_data_get(BMesh *UNUSED(bm), BMOperator *op, const c
return mapping + 1;
}
-BM_INLINE float BMO_slot_map_float_get(BMesh *bm, BMOperator *op, const char *slotname,
+BLI_INLINE float BMO_slot_map_float_get(BMesh *bm, BMOperator *op, const char *slotname,
void *element)
{
float *val = (float *) BMO_slot_map_data_get(bm, op, slotname, element);
@@ -128,7 +128,7 @@ BM_INLINE float BMO_slot_map_float_get(BMesh *bm, BMOperator *op, const char *sl
return 0.0f;
}
-BM_INLINE int BMO_slot_map_int_get(BMesh *bm, BMOperator *op, const char *slotname,
+BLI_INLINE int BMO_slot_map_int_get(BMesh *bm, BMOperator *op, const char *slotname,
void *element)
{
int *val = (int *) BMO_slot_map_data_get(bm, op, slotname, element);
@@ -137,7 +137,7 @@ BM_INLINE int BMO_slot_map_int_get(BMesh *bm, BMOperator *op, const char *slotna
return 0;
}
-BM_INLINE void *BMO_slot_map_ptr_get(BMesh *bm, BMOperator *op, const char *slotname,
+BLI_INLINE void *BMO_slot_map_ptr_get(BMesh *bm, BMOperator *op, const char *slotname,
void *element)
{
void **val = (void **) BMO_slot_map_data_get(bm, op, slotname, element);
diff --git a/source/blender/bmesh/operators/bmo_create.c b/source/blender/bmesh/operators/bmo_create.c
index 459b1cbb3a7..7db29501ed5 100644
--- a/source/blender/bmesh/operators/bmo_create.c
+++ b/source/blender/bmesh/operators/bmo_create.c
@@ -76,7 +76,7 @@ static int count_edge_faces(BMesh *bm, BMEdge *e);
/**** rotation system code * */
-BM_INLINE BMDiskLink *rs_edge_link_get(BMEdge *e, BMVert *v, EdgeData *e_data)
+BLI_INLINE BMDiskLink *rs_edge_link_get(BMEdge *e, BMVert *v, EdgeData *e_data)
{
return v == ((BMEdge *)e)->v1 ? &(((EdgeData *)e_data)->v1_disk_link) :
&(((EdgeData *)e_data)->v2_disk_link) ;
@@ -866,7 +866,7 @@ static int count_edge_faces(BMesh *bm, BMEdge *e)
return i;
}
-BM_INLINE void vote_on_winding(BMEdge *edge, EPathNode *node, unsigned int winding[2])
+BLI_INLINE void vote_on_winding(BMEdge *edge, EPathNode *node, unsigned int winding[2])
{
BMVert *test_v1, *test_v2;
/* we want to use the reverse winding to the existing order */
diff --git a/source/blender/editors/sculpt_paint/paint_vertex.c b/source/blender/editors/sculpt_paint/paint_vertex.c
index 3a6a9dd6548..bf3a7268e11 100644
--- a/source/blender/editors/sculpt_paint/paint_vertex.c
+++ b/source/blender/editors/sculpt_paint/paint_vertex.c
@@ -589,7 +589,7 @@ void vpaint_dogamma(Scene *scene)
}
#endif
-BM_INLINE unsigned int mcol_blend(unsigned int col1, unsigned int col2, int fac)
+BLI_INLINE unsigned int mcol_blend(unsigned int col1, unsigned int col2, int fac)
{
unsigned char *cp1, *cp2, *cp;
int mfac;
@@ -617,7 +617,7 @@ BM_INLINE unsigned int mcol_blend(unsigned int col1, unsigned int col2, int fac)
return col;
}
-BM_INLINE unsigned int mcol_add(unsigned int col1, unsigned int col2, int fac)
+BLI_INLINE unsigned int mcol_add(unsigned int col1, unsigned int col2, int fac)
{
unsigned char *cp1, *cp2, *cp;
int temp;
@@ -642,7 +642,7 @@ BM_INLINE unsigned int mcol_add(unsigned int col1, unsigned int col2, int fac)
return col;
}
-BM_INLINE unsigned int mcol_sub(unsigned int col1, unsigned int col2, int fac)
+BLI_INLINE unsigned int mcol_sub(unsigned int col1, unsigned int col2, int fac)
{
unsigned char *cp1, *cp2, *cp;
int temp;
@@ -667,7 +667,7 @@ BM_INLINE unsigned int mcol_sub(unsigned int col1, unsigned int col2, int fac)
return col;
}
-BM_INLINE unsigned int mcol_mul(unsigned int col1, unsigned int col2, int fac)
+BLI_INLINE unsigned int mcol_mul(unsigned int col1, unsigned int col2, int fac)
{
unsigned char *cp1, *cp2, *cp;
int mfac;
@@ -692,7 +692,7 @@ BM_INLINE unsigned int mcol_mul(unsigned int col1, unsigned int col2, int fac)
return col;
}
-BM_INLINE unsigned int mcol_lighten(unsigned int col1, unsigned int col2, int fac)
+BLI_INLINE unsigned int mcol_lighten(unsigned int col1, unsigned int col2, int fac)
{
unsigned char *cp1, *cp2, *cp;
int mfac;
@@ -725,7 +725,7 @@ BM_INLINE unsigned int mcol_lighten(unsigned int col1, unsigned int col2, int fa
return col;
}
-BM_INLINE unsigned int mcol_darken(unsigned int col1, unsigned int col2, int fac)
+BLI_INLINE unsigned int mcol_darken(unsigned int col1, unsigned int col2, int fac)
{
unsigned char *cp1, *cp2, *cp;
int mfac;
@@ -904,27 +904,27 @@ static float calc_vp_alpha_dl(VPaint *vp, ViewContext *vc,
}
-BM_INLINE float wval_blend(const float weight, const float paintval, const float alpha)
+BLI_INLINE float wval_blend(const float weight, const float paintval, const float alpha)
{
return (paintval * alpha) + (weight * (1.0f - alpha));
}
-BM_INLINE float wval_add(const float weight, const float paintval, const float alpha)
+BLI_INLINE float wval_add(const float weight, const float paintval, const float alpha)
{
return weight + (paintval * alpha);
}
-BM_INLINE float wval_sub(const float weight, const float paintval, const float alpha)
+BLI_INLINE float wval_sub(const float weight, const float paintval, const float alpha)
{
return weight - (paintval * alpha);
}
-BM_INLINE float wval_mul(const float weight, const float paintval, const float alpha)
+BLI_INLINE float wval_mul(const float weight, const float paintval, const float alpha)
{ /* first mul, then blend the fac */
return ((1.0f - alpha) + (alpha * paintval)) * weight;
}
-BM_INLINE float wval_lighten(const float weight, const float paintval, const float alpha)
+BLI_INLINE float wval_lighten(const float weight, const float paintval, const float alpha)
{
return (weight < paintval) ? wval_blend(weight, paintval, alpha) : weight;
}
-BM_INLINE float wval_darken(const float weight, const float paintval, const float alpha)
+BLI_INLINE float wval_darken(const float weight, const float paintval, const float alpha)
{
return (weight > paintval) ? wval_blend(weight, paintval, alpha) : weight;
}
diff --git a/source/blender/editors/space_text/text_ops.c b/source/blender/editors/space_text/text_ops.c
index 4c6357f7505..ba7c1f556b2 100644
--- a/source/blender/editors/space_text/text_ops.c
+++ b/source/blender/editors/space_text/text_ops.c
@@ -74,7 +74,7 @@
/************************ poll ***************************/
-BM_INLINE int text_pixel_x_to_index(SpaceText *st, const int x)
+BLI_INLINE int text_pixel_x_to_index(SpaceText *st, const int x)
{
/* add half the char width so mouse cursor selection is inbetween letters */
return (x + (st->cwidth / 2)) / st->cwidth;
diff --git a/source/blender/render/intern/source/volumetric.c b/source/blender/render/intern/source/volumetric.c
index 36895f8ad53..17c4601264a 100644
--- a/source/blender/render/intern/source/volumetric.c
+++ b/source/blender/render/intern/source/volumetric.c
@@ -69,7 +69,7 @@ extern struct Render R;
/* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ */
/* luminance rec. 709 */
-BM_INLINE float luminance(const float col[3])
+BLI_INLINE float luminance(const float col[3])
{
return (0.212671f*col[0] + 0.71516f*col[1] + 0.072169f*col[2]);
}