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:
authorKent Mein <mein@cs.umn.edu>2008-01-15 21:54:34 +0300
committerKent Mein <mein@cs.umn.edu>2008-01-15 21:54:34 +0300
commita32ddc1b85e2df0c26986b94a5efdcf6f65e5a2e (patch)
tree6e3378f987af985c305deddace35d6f38f54acae /source/blender/imbuf/intern/dds/DirectDrawSurface.cpp
parentcaf24d6a3423a680fda7691bb86adbf0390d202a (diff)
changed sqrtf to sqrt to make solaris and other platforms happy.
Kent
Diffstat (limited to 'source/blender/imbuf/intern/dds/DirectDrawSurface.cpp')
-rw-r--r--source/blender/imbuf/intern/dds/DirectDrawSurface.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/imbuf/intern/dds/DirectDrawSurface.cpp b/source/blender/imbuf/intern/dds/DirectDrawSurface.cpp
index dafe58a40a7..f842c756ce1 100644
--- a/source/blender/imbuf/intern/dds/DirectDrawSurface.cpp
+++ b/source/blender/imbuf/intern/dds/DirectDrawSurface.cpp
@@ -61,6 +61,7 @@
#include <stdio.h> // printf
#include <math.h> // sqrt
+#include <sys/types.h>
/*** declarations ***/
@@ -769,7 +770,7 @@ static Color32 buildNormal(uint8 x, uint8 y)
float nx = 2 * (x / 255.0f) - 1;
float ny = 2 * (y / 255.0f) - 1;
float nz = 0.0f;
- if (1 - nx*nx - ny*ny > 0) nz = sqrtf(1 - nx*nx - ny*ny);
+ if (1 - nx*nx - ny*ny > 0) nz = sqrt(1 - nx*nx - ny*ny);
uint8 z = clamp(int(255.0f * (nz + 1) / 2.0f), 0, 255);
return Color32(x, y, z);