diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2009-01-23 23:36:47 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2009-01-23 23:36:47 +0300 |
commit | c86579b11e6fe140f07029469e3644d7dbe0640e (patch) | |
tree | d27544e7f183f016be96c0c7d391ec9823b8c391 /source/blender/blenlib | |
parent | 4531e8e6a731af71936d09bb79a15297685ff0dc (diff) |
2.5: multiple small fixes
- wm draw method is now initialized correct when reading older
files, but the SDNA bug causing the problem is still unsolved.
is due to // char pad[8]; not being recognized as commented.
- triple buffer proxy texture test follows spec better now,
was disabling triple buffer unnecessarily on some drivers.
- some cmake compile fixes related to sequencer pthread usage
and removed bad level calls lib for player.
- show outliner header buttons in oops mode as well until that
can be switched in the UI.
- fix region data free issue for tooltips
- warning fixes
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r-- | source/blender/blenlib/intern/arithb.c | 11 | ||||
-rw-r--r-- | source/blender/blenlib/intern/graph.c | 2 |
2 files changed, 7 insertions, 6 deletions
diff --git a/source/blender/blenlib/intern/arithb.c b/source/blender/blenlib/intern/arithb.c index a21252d9aa8..a9e1e80a403 100644 --- a/source/blender/blenlib/intern/arithb.c +++ b/source/blender/blenlib/intern/arithb.c @@ -34,6 +34,7 @@ /* ************************ FUNKTIES **************************** */ +#include <stdlib.h> #include <math.h> #include <sys/types.h> #include <string.h> @@ -62,13 +63,13 @@ #define SWAP(type, a, b) { type sw_ap; sw_ap=(a); (a)=(b); (b)=sw_ap; } #define CLAMP(a, b, c) if((a)<(b)) (a)=(b); else if((a)>(c)) (a)=(c) - -#if defined(WIN32) || defined(__APPLE__) -#include <stdlib.h> +#ifndef M_PI #define M_PI 3.14159265358979323846 -#define M_SQRT2 1.41421356237309504880 +#endif -#endif /* defined(WIN32) || defined(__APPLE__) */ +#ifndef M_SQRT2 +#define M_SQRT2 1.41421356237309504880 +#endif float saacos(float fac) diff --git a/source/blender/blenlib/intern/graph.c b/source/blender/blenlib/intern/graph.c index 03a565ef0bf..de9c8860c6a 100644 --- a/source/blender/blenlib/intern/graph.c +++ b/source/blender/blenlib/intern/graph.c @@ -279,7 +279,7 @@ void BLI_removeDoubleNodes(BGraph *graph, float limit) BNode * BLI_FindNodeByPosition(BGraph *graph, float *p, float limit) { BNode *closest_node = NULL, *node; - float min_distance; + float min_distance = 0.0f; for(node = graph->nodes.first; node; node = node->next) { |