aboutsummaryrefslogtreecommitdiff
path: root/core/math.odin
diff options
context:
space:
mode:
authorZachary Pierson <zacpiersonhehe@gmail.com>2017-03-30 00:26:46 -0500
committerZachary Pierson <zacpiersonhehe@gmail.com>2017-03-30 00:26:46 -0500
commit1349aa6f2cfc63ace0382a8dd6b346f24e861ea9 (patch)
tree55b6fb23ecfb86e3c474bfd4bbc8e9bb5c78f986 /core/math.odin
parent7a28827602f29f0e9485ca6617daf316635802df (diff)
parenta75ccb6fbc529d2fee00f9b456ca7c0c830548ee (diff)
Merge https://github.com/gingerBill/Odin, cleaned up a bit, fixed the object file version message on macOS
Diffstat (limited to 'core/math.odin')
-rw-r--r--core/math.odin4
1 files changed, 4 insertions, 0 deletions
diff --git a/core/math.odin b/core/math.odin
index 7e1e0bb07..059f3e338 100644
--- a/core/math.odin
+++ b/core/math.odin
@@ -36,6 +36,10 @@ cos :: proc(x: f64) -> f64 #foreign __llvm_core "llvm.cos.f64";
tan :: proc(x: f32) -> f32 #inline { return sin(x)/cos(x); }
tan :: proc(x: f64) -> f64 #inline { return sin(x)/cos(x); }
+pow :: proc(x, power: f32) -> f32 #foreign __llvm_core "llvm.pow.f32";
+pow :: proc(x, power: f64) -> f64 #foreign __llvm_core "llvm.pow.f64";
+
+
lerp :: proc(a, b, t: f32) -> f32 { return a*(1-t) + b*t; }
lerp :: proc(a, b, t: f64) -> f64 { return a*(1-t) + b*t; }