import portability fixes from Chrome around floats
move porting functions for SkDebugf into /ports directory
git-svn-id: http://skia.googlecode.com/svn/trunk@147 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/include/core/SkFloatingPoint.h b/include/core/SkFloatingPoint.h
index 68bf6ef..e6856cf 100644
--- a/include/core/SkFloatingPoint.h
+++ b/include/core/SkFloatingPoint.h
@@ -25,6 +25,12 @@
#include <float.h>
#include "SkFloatBits.h"
+// If math.h had powf(float, float), I could remove this wrapper
+static inline float sk_float_pow(float base, float exp) {
+ return static_cast<float>(pow(static_cast<double>(base),
+ static_cast<double>(exp)));
+}
+
#ifdef SK_BUILD_FOR_WINCE
#define sk_float_sqrt(x) (float)::sqrt(x)
#define sk_float_sin(x) (float)::sin(x)