From 1247157de6d55146f6c544bd47c21a5326a64725 Mon Sep 17 00:00:00 2001 From: imushir Date: Fri, 27 Nov 2015 15:47:47 +0530 Subject: #define for u8 u16 i8 i16 added --- src/c/operations/includes/division.h | 80 ++++++++++++++++++++++++++++++ src/c/operations/includes/multiplication.h | 36 ++++++++++++++ 2 files changed, 116 insertions(+) (limited to 'src/c/operations/includes') diff --git a/src/c/operations/includes/division.h b/src/c/operations/includes/division.h index eedf4a3..ac2d148 100644 --- a/src/c/operations/includes/division.h +++ b/src/c/operations/includes/division.h @@ -102,14 +102,46 @@ EXTERN_OPERATIONS doubleComplex zrdivs (doubleComplex in1, doubleComplex in2); */ EXTERN_OPERATIONS void zrdiva(doubleComplex* in1, doubleComplex* in2, int size, doubleComplex* out ); + +/* +** \brief Compute a right division element ways for uint8. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 ./ in2. +*/ +EXTERN_OPERATIONS void u8rdiva (uint8* in1, uint8* in2, int size, uint8* out ); + + + /* ** \brief Compute a right division for uint8. ** \param in1 : input uint8. ** \param in2 : input uint8. ** \return in1 / in2 = in1 ./ in2. */ + EXTERN_OPERATIONS uint8 u8rdivs (uint8 in1, uint8 in2); +/* +** \brief Compute a right division element ways for uint16. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 ./ in2. +*/ +EXTERN_OPERATIONS void u16rdiva (uint16* in1, uint16* in2, int size, uint16* out ); + + +/* +** \brief Compute a right division element ways for int8. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 ./ in2. +*/ +EXTERN_OPERATIONS void i8rdiva (int8* in1, int8* in2, int size, int8* out ); + /* ** \brief Compute a right division for int8. ** \param in1 : input int8. @@ -134,6 +166,16 @@ EXTERN_OPERATIONS uint16 u16rdivs (uint16 in1, uint16 in2); */ EXTERN_OPERATIONS int16 i16rdivs (int16 in1, int16 in2); +/* +** \brief Compute a right division element ways for int16. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 ./ in2. +*/ +EXTERN_OPERATIONS void i16rdiva (int16* in1, int16* in2, int size, int16* out ); + + /* ** LEFT DIVISION */ @@ -206,6 +248,15 @@ EXTERN_OPERATIONS doubleComplex zldivs (doubleComplex in1, doubleComplex in2); */ EXTERN_OPERATIONS void zldiva(doubleComplex* in1, doubleComplex* in2, int size, doubleComplex* out ); +/* +** \brief Compute a left division element ways for uint8. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 .\ in2. +*/ +EXTERN_OPERATIONS void u8ldiva (uint8* in1, uint8* in2, int size, uint8* out ); + /* ** \brief Compute a right division for uint8. ** \param in1 : input uint8. @@ -214,6 +265,15 @@ EXTERN_OPERATIONS void zldiva(doubleComplex* in1, doubleComplex* in2, int size, */ EXTERN_OPERATIONS uint8 u8ldivs (uint8 in1, uint8 in2); +/* +** \brief Compute a left division element ways for int8. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 .\ in2. +*/ +EXTERN_OPERATIONS void i8ldiva (int8* in1, int8* in2, int size, int8* out ); + /* ** \brief Compute a right division for int8. ** \param in1 : input int8. @@ -222,6 +282,16 @@ EXTERN_OPERATIONS uint8 u8ldivs (uint8 in1, uint8 in2); */ EXTERN_OPERATIONS int8 i8ldivs (int8 in1, int8 in2); +/* +** \brief Compute a left division element ways for uint16. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 .\ in2. +*/ +EXTERN_OPERATIONS void u16ldiva (uint16* in1, uint16* in2, int size, uint16* out ); + + /* ** \brief Compute a right division for uint16. ** \param in1 : input uint16. @@ -230,6 +300,16 @@ EXTERN_OPERATIONS int8 i8ldivs (int8 in1, int8 in2); */ EXTERN_OPERATIONS uint16 u16ldivs (uint16 in1, uint16 in2); +/* +** \brief Compute a left division element ways for int16. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array = rows*columns. +** \param out : array that contains the division in1 .\ in2. +*/ +EXTERN_OPERATIONS void i16ldiva (int16* in1, int16* in2, int size, int16* out ); + + /* ** \brief Compute a right division for int16. ** \param in1 : input int16. diff --git a/src/c/operations/includes/multiplication.h b/src/c/operations/includes/multiplication.h index 8b08d6d..32ea932 100644 --- a/src/c/operations/includes/multiplication.h +++ b/src/c/operations/includes/multiplication.h @@ -141,6 +141,15 @@ EXTERN_OPERATIONS doubleComplex zmulzdv(doubleComplex *in1, double *in2, int siz EXTERN_OPERATIONS doubleComplex zmuldzv(double *in1, doubleComplex *in2, int size2); +/* +** \brief Compute a multiplication element ways for uint8. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array. +** \param out : array that contains the multiplication = in1 .* in2. +*/ +EXTERN_OPERATIONS void u8mula(uint8 *in1, uint8 *in2, int size,uint8 * out); + /* ** \brief Compute a multiplication with uint8. ** \param in1 : input uint8. @@ -158,6 +167,15 @@ EXTERN_OPERATIONS uint8 u8muls(uint8 in1, uint8 in2); */ EXTERN_OPERATIONS uint8 u8mulv(uint8 *in1, uint8 *in2, int size2); +/* +** \brief Compute a multiplication element ways for int8. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array. +** \param out : array that contains the multiplication = in1 .* in2. +*/ +EXTERN_OPERATIONS void i8mula(int8 *in1, int8 *in2, int size,int8 * out); + /* ** \brief Compute a multiplication with int8. ** \param in1 : input int8. @@ -175,6 +193,15 @@ EXTERN_OPERATIONS int8 i8muls(int8 in1, int8 in2); */ EXTERN_OPERATIONS int8 i8mulv(int8 *in1, int8 *in2, int size2); +/* +** \brief Compute a multiplication element ways for uint16. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array. +** \param out : array that contains the multiplication = in1 .* in2. +*/ +EXTERN_OPERATIONS void u16mula(uint16 *in1, uint16 *in2, int size,uint16 * out); + /* ** \brief Compute a multiplication with uint16. ** \param in1 : input uint16. @@ -192,6 +219,15 @@ EXTERN_OPERATIONS uint16 u16muls(uint16 in1, uint16 in2); */ EXTERN_OPERATIONS uint16 u16mulv(uint16 *in1, uint16 *in2, int size2); +/* +** \brief Compute a multiplication element ways for int16. +** \param in1 : input array. +** \param in2 : input array. +** \param size : size of in2 array. +** \param out : array that contains the multiplication = in1 .* in2. +*/ +EXTERN_OPERATIONS void i16mula(int16 *in1, int16 *in2, int size,int16 * out); + /* ** \brief Compute a multiplication with int16. ** \param in1 : input int16. -- cgit