aboutsummaryrefslogtreecommitdiff
path: root/standard.h
diff options
context:
space:
mode:
Diffstat (limited to 'standard.h')
-rw-r--r--standard.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/standard.h b/standard.h
new file mode 100644
index 0000000..392425c
--- /dev/null
+++ b/standard.h
@@ -0,0 +1,22 @@
+#ifndef standard_h
+#define standard_h
+
+int string_equal(const char* a, const char* b);
+
+#define fbits 9
+
+#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);
+
+/* Not safe! */
+int f_to_buf(int f, char* buf);
+int int_to_buf(int n, char* buf);
+
+#endif