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
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2010-09-25 15:30:46 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2010-09-25 15:30:46 +0400
commit0d3f0ff08e2066de33165fa3153fd081fc394aaa (patch)
tree7e2a35a4d78b811c464a0df6e48a75963595f1b1 /source/blender/blenlib/intern/math_base_inline.c
parentd305a64b69a6181dfde1f7cc14c6b9d579140da0 (diff)
Fix #23901: displace node not working with negative values.
Diffstat (limited to 'source/blender/blenlib/intern/math_base_inline.c')
-rw-r--r--source/blender/blenlib/intern/math_base_inline.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/math_base_inline.c b/source/blender/blenlib/intern/math_base_inline.c
index b364ff73e4f..fc413457122 100644
--- a/source/blender/blenlib/intern/math_base_inline.c
+++ b/source/blender/blenlib/intern/math_base_inline.c
@@ -122,5 +122,10 @@ MINLINE float maxf(float a, float b)
return (a > b)? a: b;
}
+MINLINE float signf(float f)
+{
+ return (f < 0.f)? -1.f: 1.f;
+}
+
#endif /* BLI_MATH_BASE_INLINE */