SameBoy | Accurate GB/GBC emulator |
| download: https://git.y1.nz/archives/sameboy.tar.gz | |
| README | Files | Log | Refs | LICENSE |
Windows/math.c
1 #include <math.h>
2
3 #ifdef USE_MSVCRT_DLL
4
5 /* "Old" (Pre-2015) Windows headers/libc don't have round and exp2. */
6
7 __attribute__((no_builtin)) double round(double f)
8 {
9 return f >= 0? (int)(f + 0.5) : (int)(f - 0.5);
10 }
11
12
13 __attribute__((no_builtin)) double exp2(double f)
14 {
15 return pow(2, f);
16 }
17
18 #endif
This webpage is intended to be an accessible preview of this repository. To get a fuller picture, clone it and use the git CLI.