From b9df76dd2c1ce41b715274eb92545f0dec0fc9d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Branimir=20Karad=C5=BEi=C4=87?= Date: Wed, 13 Aug 2014 19:53:19 -0700 Subject: [PATCH] Added fpulse. --- include/bx/fpumath.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/bx/fpumath.h b/include/bx/fpumath.h index 54413fa..2eccb64 100644 --- a/include/bx/fpumath.h +++ b/include/bx/fpumath.h @@ -69,6 +69,11 @@ namespace bx return _a < _edge ? 0.0f : 1.0f; } + inline float fpulse(float _a, float _start, float _end) + { + return fstep(_a, _start) - fstep(_a, _end); + } + inline float fabsolute(float _a) { return fabsf(_a);