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:
authorJoerg Mueller <nexyon@gmail.com>2010-03-20 23:00:15 +0300
committerJoerg Mueller <nexyon@gmail.com>2010-03-20 23:00:15 +0300
commitd904da1d03f2312944dc1b66215326aeefc0ec55 (patch)
tree5d914bda187a6786dfee2b857dde14c93a627351 /source/blender/blenlib
parentb6a111a6db9dd67e4aabaa366e5c2204e222e7cc (diff)
Yet another try to get NaN working on MSVC.
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r--source/blender/blenlib/BLI_math_base.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/blenlib/BLI_math_base.h b/source/blender/blenlib/BLI_math_base.h
index 28c5026910f..cf3fda8ad36 100644
--- a/source/blender/blenlib/BLI_math_base.h
+++ b/source/blender/blenlib/BLI_math_base.h
@@ -70,7 +70,8 @@ extern "C" {
#define M_LN10 2.30258509299404568402
#endif
#ifndef NAN
-#define NAN (0.0/0.0)
+static __const char __qnan__[8] = { 0, 0, 0, 0, 0, 0, 0xf8, 0x7f };
+#define NAN (*(__const double *) __qnan__)
#endif
#ifndef sqrtf