summaryrefslogtreecommitdiffstats
path: root/src/core/common.h
diff options
context:
space:
mode:
authorFire-Head <Fire-Head@users.noreply.github.com>2020-04-01 23:04:56 +0200
committerFire-Head <Fire-Head@users.noreply.github.com>2020-04-01 23:04:56 +0200
commit13fb853fd832d4ba92983c968856ba04e8e13dcb (patch)
treed6bdb7be2e523ae7ece3071b739d66d2b8191f0c /src/core/common.h
parentMerge pull request #366 from Nick007J/master (diff)
downloadre3-13fb853fd832d4ba92983c968856ba04e8e13dcb.tar
re3-13fb853fd832d4ba92983c968856ba04e8e13dcb.tar.gz
re3-13fb853fd832d4ba92983c968856ba04e8e13dcb.tar.bz2
re3-13fb853fd832d4ba92983c968856ba04e8e13dcb.tar.lz
re3-13fb853fd832d4ba92983c968856ba04e8e13dcb.tar.xz
re3-13fb853fd832d4ba92983c968856ba04e8e13dcb.tar.zst
re3-13fb853fd832d4ba92983c968856ba04e8e13dcb.zip
Diffstat (limited to '')
-rw-r--r--src/core/common.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/core/common.h b/src/core/common.h
index 7b4ff4a0..b58b93af 100644
--- a/src/core/common.h
+++ b/src/core/common.h
@@ -215,6 +215,7 @@ void re3_assert(const char *expr, const char *filename, unsigned int lineno, con
#define ABS(a) (((a) < 0) ? (-(a)) : (a))
#define norm(value, min, max) (((value) < (min)) ? 0 : (((value) > (max)) ? 1 : (((value) - (min)) / ((max) - (min)))))
+#define lerp(norm, min, max) ( (norm) * ((max) - (min)) + (min) )
#define STRINGIFY(x) #x
#define STR(x) STRINGIFY(x)