From 6e66ddf5ed29c2593dbd25d4fd48b36c2e68e411 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Sun, 11 Oct 2015 01:44:47 +0200 Subject: Fix warnings and remove casts by adding copy_vx_vx_uchar() functions. --- source/blender/blenlib/BLI_math_vector.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'source/blender/blenlib/BLI_math_vector.h') diff --git a/source/blender/blenlib/BLI_math_vector.h b/source/blender/blenlib/BLI_math_vector.h index fc0dd76b003..01c00ddb48e 100644 --- a/source/blender/blenlib/BLI_math_vector.h +++ b/source/blender/blenlib/BLI_math_vector.h @@ -61,11 +61,14 @@ MINLINE void swap_v2_v2(float a[2], float b[2]); MINLINE void swap_v3_v3(float a[3], float b[3]); MINLINE void swap_v4_v4(float a[4], float b[4]); +/* unsigned char */ +MINLINE void copy_v2_v2_uchar(unsigned char r[2], const unsigned char a[2]); +MINLINE void copy_v3_v3_uchar(unsigned char r[3], const unsigned char a[3]); +MINLINE void copy_v4_v4_uchar(unsigned char r[4], const unsigned char a[4]); /* char */ MINLINE void copy_v2_v2_char(char r[2], const char a[2]); MINLINE void copy_v3_v3_char(char r[3], const char a[3]); MINLINE void copy_v4_v4_char(char r[4], const char a[4]); - /* short */ MINLINE void copy_v2_v2_short(short r[2], const short a[2]); MINLINE void copy_v3_v3_short(short r[3], const short a[3]); -- cgit v1.2.3