mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
[mathlib] Add Blend macro
The Blend macro supports any non-integral type supporting * and + (float, double, vec4f_t, etc), so it is essentially a scalar VectorBlend or QuatBlend.
This commit is contained in:
parent
e6bc5e3e11
commit
8b6136e6f5
1 changed files with 2 additions and 0 deletions
|
@ -57,6 +57,8 @@ extern int nanmask;
|
|||
|
||||
#define IS_NAN(x) (((*(int *) (char *) &x) & nanmask) == nanmask)
|
||||
|
||||
#define Blend(a,b,blend) ((1 - (blend)) * (a) + (blend) * (b))
|
||||
|
||||
#include "QF/math/vector.h"
|
||||
#include "QF/math/quaternion.h"
|
||||
#include "QF/math/dual.h"
|
||||
|
|
Loading…
Reference in a new issue