blob: 88918af69e509ded36d58110c6b2b7081512e5f4 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#ifndef standard_h
#define standard_h
int string_equal(const char* a, const char* b);
#define fbits 9
#define fscale_lower_limit 16
#define fscale_upper_limit 900
#define fscale_factor 16
#define mini(a_, b_) ((a_) < (b_) ? (a_) : (b_))
#define maxi(a_, b_) ((a_) > (b_) ? (a_) : (b_))
int absolute(int x);
int fsin(int t);
int fcos(int t);
int ftan(int t);
int flerp(int a, int b, int t);
int fsqrt(int v);
void vec_minise(int* x, int* y);
void vec_nrmise(int* x, int* y);
void seed_rng(unsigned seed);
unsigned get_seed();
unsigned rng();
int rand_range(int a, int b);
int randf();
/* Not safe! */
int f_to_buf(int f, char* buf);
int int_to_buf(int n, char* buf);
#endif
|