mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-13 07:58:04 +00:00
lround for MSVC
git-svn-id: https://svn.eduke32.com/eduke32@4527 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
398d20fc5f
commit
9378066660
1 changed files with 7 additions and 0 deletions
|
@ -159,6 +159,13 @@ static inline float nearbyintf(float x)
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include <math.h>
|
||||||
|
static inline long lround(double num)
|
||||||
|
{
|
||||||
|
return (long) (num > 0 ? num + 0.5 : ceil(num - 0.5));
|
||||||
|
}
|
||||||
|
|
||||||
#else
|
#else
|
||||||
# define longlong(x) x##ll
|
# define longlong(x) x##ll
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue