mirror of
https://github.com/g-truc/glm.git
synced 2025-04-13 08:43:00 +00:00
Fixed isnan and isinf on Android
This commit is contained in:
parent
6525d84e3b
commit
173b009d1f
2 changed files with 13 additions and 2 deletions
|
@ -16,3 +16,14 @@
|
|||
#ifdef min
|
||||
#undef min
|
||||
#endif
|
||||
|
||||
//! Workaround for Android
|
||||
#ifdef isnan
|
||||
#undef isnan
|
||||
#endif
|
||||
|
||||
//! Workaround for Android
|
||||
#ifdef isinf
|
||||
#undef isinf
|
||||
#endif
|
||||
|
||||
|
|
|
@ -1211,7 +1211,7 @@ namespace glm
|
|||
#if(GLM_COMPILER & GLM_COMPILER_VC)
|
||||
return typename genType::bool_type(_isnan(x));
|
||||
#elif(defined(ANDROID))
|
||||
return typename genType::bool_type(isnan(x));
|
||||
return typename genType::bool_type(isnanf(x));
|
||||
#else
|
||||
return typename genType::bool_type(std::isnan(x));
|
||||
#endif
|
||||
|
@ -1264,7 +1264,7 @@ namespace glm
|
|||
#if(GLM_COMPILER & GLM_COMPILER_VC)
|
||||
return typename genType::bool_type(_fpclass(x) == _FPCLASS_NINF || _fpclass(x) == _FPCLASS_PINF);
|
||||
#elif(defined(ANDROID))
|
||||
return typename genType::bool_type(isinf(x));
|
||||
return typename genType::bool_type(__isinf(x));
|
||||
#else
|
||||
return typename genType::bool_type(std::isinf(x));
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue