Branimir Karadžić 7 년 전
부모
커밋
ad4813beea
1개의 변경된 파일24개의 추가작업 그리고 40개의 파일을 삭제
  1. 24 40
      src/crtnone.cpp

+ 24 - 40
src/crtnone.cpp

@@ -5,6 +5,7 @@
 
 
 #include "bx_p.h"
 #include "bx_p.h"
 #include <bx/debug.h>
 #include <bx/debug.h>
+#include <bx/math.h>
 #include <bx/sort.h>
 #include <bx/sort.h>
 #include <bx/readerwriter.h>
 #include <bx/readerwriter.h>
 
 
@@ -125,32 +126,29 @@ extern "C" int abs(int _value)
 	return _value >= 0 ? _value : -_value;
 	return _value >= 0 ? _value : -_value;
 }
 }
 
 
-extern "C" float fabsf(float _value)
+extern "C" float fabsf(float _x)
 {
 {
-	return _value >= 0.0f ? _value : -_value;
+	return bx::abs(_x);
 }
 }
 
 
-extern "C" double fabs(double _value)
+extern "C" double fabs(double _x)
 {
 {
-	return _value >= 0.0 ? _value : -_value;
+	return bx::abs(_x);
 }
 }
 
 
 extern "C" double ldexp(double _x, int _exp)
 extern "C" double ldexp(double _x, int _exp)
 {
 {
-	BX_UNUSED(_x, _exp);
-	return 0.0;
+	return ldexp(float(_x), _exp);
 }
 }
 
 
 extern "C" float expf(float _x)
 extern "C" float expf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::exp(_x);
 }
 }
 
 
 extern "C" float logf(float _x)
 extern "C" float logf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::log(_x);
 }
 }
 
 
 extern "C" float log10f(float _x)
 extern "C" float log10f(float _x)
@@ -159,88 +157,74 @@ extern "C" float log10f(float _x)
 	return 0.0f;
 	return 0.0f;
 }
 }
 
 
-extern "C" float powf(float _x)
+extern "C" float powf(float _x, float _y)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::pow(_x, _y);
 }
 }
 
 
-extern "C" double pow(double _x)
+extern "C" double pow(double _x, float _y)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0;
+	return bx::pow(_x, _y);
 }
 }
 
 
 extern "C" float sinf(float _x)
 extern "C" float sinf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::sin(_x);
 }
 }
 
 
 extern "C" float cosf(float _x)
 extern "C" float cosf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::cos(_x);
 }
 }
 
 
 extern "C" float tanf(float _x)
 extern "C" float tanf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::tan(_x);
 }
 }
 
 
 extern "C" float atan2f(float _y, float _x)
 extern "C" float atan2f(float _y, float _x)
 {
 {
-	BX_UNUSED(_y, _x);
-	return 0.0f;
+	return bx::atan2(_y, _x);
 }
 }
 
 
 extern "C" float sqrtf(float _x)
 extern "C" float sqrtf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::sqrt(_x);
 }
 }
 
 
 extern "C" double sqrt(double _x)
 extern "C" double sqrt(double _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0;
+	return bx::sqrt(_x);
 }
 }
 
 
 extern "C" float ceilf(float _x)
 extern "C" float ceilf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::ceil(_x);
 }
 }
 
 
 extern "C" double ceil(double _x)
 extern "C" double ceil(double _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0;
+	return bx::ceil(_x);
 }
 }
 
 
 extern "C" float floorf(float _x)
 extern "C" float floorf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::floor(_x);
 }
 }
 
 
 extern "C" double floor(double _x)
 extern "C" double floor(double _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0;
+	return bx::floor(_x);
 }
 }
 
 
 extern "C" float acosf(float _x)
 extern "C" float acosf(float _x)
 {
 {
-	BX_UNUSED(_x);
-	return 0.0f;
+	return bx::acos(_x);
 }
 }
 
 
 extern "C" float fmodf(float _numer, float _denom)
 extern "C" float fmodf(float _numer, float _denom)
 {
 {
-	BX_UNUSED(_numer, _denom);
-	return 0.0f;
+	return bx::mod(_numer, _denom);
 }
 }
 
 
 extern "C" int atoi(const char* _str)
 extern "C" int atoi(const char* _str)