Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYimingWu <xp8110@outlook.com>2019-08-20 16:09:55 +0300
committerYimingWu <xp8110@outlook.com>2019-08-20 16:09:55 +0300
commit8bee9af462238936087e0056d97cf086c2f7059a (patch)
treea103e0e42dccc788f5897782837093ce724e106d /source/blender/blenlib/intern/math_vector.c
parenta942d97b7971dc0e7add44e3e9ba1c02fb914f7d (diff)
BLI: double version of some math functions.
Diffstat (limited to 'source/blender/blenlib/intern/math_vector.c')
-rw-r--r--source/blender/blenlib/intern/math_vector.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/math_vector.c b/source/blender/blenlib/intern/math_vector.c
index 1977558ac88..961850d3a9a 100644
--- a/source/blender/blenlib/intern/math_vector.c
+++ b/source/blender/blenlib/intern/math_vector.c
@@ -1392,4 +1392,21 @@ void mul_vn_db(double *array_tar, const int size, const double f)
}
}
+void interp_v3_v3v3_db(double target[3], const double a[3], const double b[3], const double t)
+{
+ const double s = 1.0f - t;
+
+ target[0] = s * a[0] + t * b[0];
+ target[1] = s * a[1] + t * b[1];
+ target[2] = s * a[2] + t * b[2];
+}
+
+void interp_v2_v2v2_db(double target[2], const double a[2], const double b[2], const double t)
+{
+ const double s = 1.0f - t;
+
+ target[0] = s * a[0] + t * b[0];
+ target[1] = s * a[1] + t * b[1];
+}
+
/** \} */