diff options
Diffstat (limited to 'source/blender/blenlib/intern/math_vector_inline.c')
-rw-r--r-- | source/blender/blenlib/intern/math_vector_inline.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/source/blender/blenlib/intern/math_vector_inline.c b/source/blender/blenlib/intern/math_vector_inline.c index c8e8ff9602b..cce78b5e5d2 100644 --- a/source/blender/blenlib/intern/math_vector_inline.c +++ b/source/blender/blenlib/intern/math_vector_inline.c @@ -271,6 +271,12 @@ MINLINE void add_v2_v2v2(float r[2], const float a[2], const float b[2]) r[1] = a[1] + b[1]; } +MINLINE void add_v2_v2v2_int(int r[2], const int a[2], const int b[2]) +{ + r[0] = a[0] + b[0]; + r[1] = a[1] + b[1]; +} + MINLINE void add_v3_v3(float r[3], const float a[3]) { r[0] += a[0]; @@ -313,6 +319,12 @@ MINLINE void sub_v2_v2v2(float r[2], const float a[2], const float b[2]) r[1] = a[1] - b[1]; } +MINLINE void sub_v2_v2v2_int(int r[2], const int a[2], const int b[2]) +{ + r[0] = a[0] - b[0]; + r[1] = a[1] - b[1]; +} + MINLINE void sub_v3_v3(float r[3], const float a[3]) { r[0] -= a[0]; |