Changeset 826 for soft/giet_vm/applications/rosenfeld/nrc2/include
- Timestamp:
- Jul 13, 2017, 11:01:58 AM (7 years ago)
- Location:
- soft/giet_vm/applications/rosenfeld/nrc2/include
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
soft/giet_vm/applications/rosenfeld/nrc2/include/nralloc2.h
r821 r826 77 77 #undef remote_type_matrix 78 78 #define remote_type_matrix(t) \ 79 t ** short_name(t,remote_,matrix)(int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch )79 t ** short_name(t,remote_,matrix)(int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t x, int32_t y) 80 80 81 81 remote_type_matrix(int8_t); -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrc_os_config.h
r821 r826 5 5 6 6 #if TARGET_OS == GIETVM 7 #define tokenize(x) #x 7 8 #define printf(...) giet_tty_printf(__VA_ARGS__) 9 #define assert(x) giet_pthread_assert(x, "Assert failed.") 8 10 9 11 #define open(x, y) giet_fat_open(x, y) … … 20 22 #define pthread_spin_unlock(x) lock_release(x) 21 23 #define pthread_spin_init(x, y) lock_init(x) 22 #define pthread_mutex lock_tuser_lock_t24 #define pthread_mutex_t user_lock_t 23 25 #define pthread_mutex_lock(x) lock_acquire(x) 24 26 #define pthread_mutex_unlock(x) lock_release(x) -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrmem1x.h
r772 r826 4 4 */ 5 5 6 IMAGE_EXPORT(void) convert_rgb32vector_rgb8vector(rgb32 *x, long nl, long nh, rgb8 *y); 6 void roll_si16vector(int16_t * v, int32_t nl, int32_t nh); 7 void roll_ui16vector(uint16_t * v, int32_t nl, int32_t nh); 7 8 8 IMAGE_EXPORT(void) roll_svector(sint16 *v, long nl, long nh); 9 #define copy_type_vector(t) \ 10 void short_name(t,copy_,vector)(t * src, int32_t nl1, int32_t nh1, t * dst, int32_t nl2, int32_t nh2); \ 11 void short_name(t,copy1c_,vector)(t * src, int32_t nc, t * dst, int32_t nl, int32_t nh); \ 12 void short_name(t,copy_,vector_mod)(t * src, int32_t nl, int32_t nh, int32_t m, t * dst); 9 13 10 IMAGE_EXPORT(void) move_ui8vector_1left_block (uint8 *v, long nl, long nh); 11 IMAGE_EXPORT(void) move_ui16vector_1left_block(uint16 *v, long nl, long nh); 12 IMAGE_EXPORT(void) move_si16vector_1left_block(sint16 *v, long nl, long nh); 13 IMAGE_EXPORT(void) move_ui32vector_1left_block(uint32 *v, long nl, long nh); 14 IMAGE_EXPORT(void) move_si32vector_1left_block(sint32 *v, long nl, long nh); 14 copy_type_vector(int8_t); 15 copy_type_vector(uint8_t); 16 copy_type_vector(int16_t); 17 copy_type_vector(uint16_t); 18 copy_type_vector(int32_t); 19 copy_type_vector(uint32_t); 20 copy_type_vector(float); 21 copy_type_vector(double); 22 copy_type_vector(rgb8); 23 copy_type_vector(rgbx8); 15 24 16 IMAGE_EXPORT(void) move_ui8vector_1right_block (uint8 *v, long nl, long nh);17 IMAGE_EXPORT(void) move_ui16vector_1right_block(uint16 *v, long nl, long nh);18 IMAGE_EXPORT(void) move_si16vector_1right_block(sint16 *v, long nl, long nh);19 IMAGE_EXPORT(void) move_ui32vector_1right_block(uint32 *v, long nl, long nh);20 IMAGE_EXPORT(void) move_si32vector_1right_block(sint32 *v, long nl, long nh);21 25 22 IMAGE_EXPORT(void) copy1c_bvector (uint8 *src, long nc, uint8 *dst, long nl, long nh); 23 IMAGE_EXPORT(void) copy1c_si16vector (sint16 *src, long nc, sint16 *dst, long nl, long nh); 24 IMAGE_EXPORT(void) copy1c_ui16vector (uint16 *src, long nc, uint16 *dst, long nl, long nh); 25 IMAGE_EXPORT(void) copy1c_ui32vector (uint32 *src, long nc, uint32 *dst, long nl, long nh); 26 IMAGE_EXPORT(void) copy1c_f32vector (float32 *src, long nc, float32 *dst, long nl, long nh); 27 IMAGE_EXPORT(void) copy1c_f64vector (float64 *src, long nc, float64 *dst, long nl, long nh); 28 IMAGE_EXPORT(void) copy1c_rgb8vector (rgb8 *src, long nc, rgb8 *dst, long nl, long nh); 29 IMAGE_EXPORT(void) copy1c_rgbx8vector(rgbx8 *src, long nc, rgbx8 *dst, long nl, long nh); 26 // Local Variables: 27 // tab-width: 4 28 // c-basic-offset: 4 29 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 30 // indent-tabs-mode: nil 31 // End: 30 32 31 IMAGE_EXPORT(void) copy_ui8vector_mod (uint8 *src, long nl, long nh, long m, uint8 *dst); 32 IMAGE_EXPORT(void) copy_ui16vector_mod(uint16 *src, long nl, long nh, long m, uint16 *dst); 33 IMAGE_EXPORT(void) copy_si16vector_mod(sint16 *src, long nl, long nh, long m, sint16 *dst); 34 IMAGE_EXPORT(void) copy_ui32vector_mod(uint32 *src, long nl, long nh, long m, uint32 *dst); 35 IMAGE_EXPORT(void) copy_si32vector_mod(sint32 *src, long nl, long nh, long m, sint32 *dst); 36 IMAGE_EXPORT(void) copy_f32vector_mod (float32 *src, long nl, long nh, long m, float32 *dst); 37 IMAGE_EXPORT(void) copy_f64vector_mod (float64 *src, long nl, long nh, long m, float64 *dst); 33 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 34 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrmem2.h
r772 r826 11 11 #define _NRMEM2_H_ 12 12 13 #ifdef __cplusplus14 #ifdef PRAGMA_VERBOSE15 #pragma message ("C++")16 #endif17 extern "C" {18 #endif19 20 21 13 /* 22 14 * ------------------ … … 25 17 */ 26 18 27 IMAGE_EXPORT(void) dup_si8matrix (sint8 **X, long nrl,long nrh,long ncl, long nch, sint8 **Y); 28 IMAGE_EXPORT(void) dup_ui8matrix (uint8 **X, long nrl,long nrh,long ncl, long nch, uint8 **Y); 29 IMAGE_EXPORT(void) dup_si16matrix (sint16 **X, long nrl,long nrh,long ncl, long nch, sint16 **Y); 30 IMAGE_EXPORT(void) dup_ui16matrix (uint16 **X, long nrl,long nrh,long ncl, long nch, uint16 **Y); 31 IMAGE_EXPORT(void) dup_si32matrix (sint32 **X, long nrl,long nrh,long ncl, long nch, sint32 **Y); 32 IMAGE_EXPORT(void) dup_ui32matrix (uint32 **X, long nrl,long nrh,long ncl, long nch, uint32 **Y); 33 IMAGE_EXPORT(void) dup_si64matrix (sint64 **X, long nrl,long nrh,long ncl, long nch, sint64 **Y); 34 IMAGE_EXPORT(void) dup_ui64matrix (uint64 **X, long nrl,long nrh,long ncl, long nch, uint64 **Y); 19 #define dup_type_matrix(t) \ 20 void short_name(t,dup_,matrix)(t ** X, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** Y); 35 21 36 IMAGE_EXPORT(void) dup_f32matrix (float32 **X, long nrl,long nrh,long ncl, long nch, float32 **Y); 37 IMAGE_EXPORT(void) dup_f64matrix (float64 **X, long nrl,long nrh,long ncl, long nch, float64 **Y); 22 dup_type_matrix(int8_t); 23 dup_type_matrix(uint8_t); 24 dup_type_matrix(int16_t); 25 dup_type_matrix(uint16_t); 26 dup_type_matrix(int32_t); 27 dup_type_matrix(uint32_t); 28 dup_type_matrix(int64_t); 29 dup_type_matrix(uint64_t); 30 dup_type_matrix(float); 31 dup_type_matrix(double); 32 dup_type_matrix(rgb8); 33 dup_type_matrix(rgbx8); 38 34 39 IMAGE_EXPORT(void) dup_rgb8matrix (rgb8 **X, long nrl,long nrh,long ncl, long nch, rgb8 **Y);40 IMAGE_EXPORT(void) dup_rgbx8matrix (rgbx8 **X, long nrl,long nrh,long ncl, long nch, rgbx8 **Y);41 35 42 36 … … 47 41 */ 48 42 49 IMAGE_EXPORT(void) resize_si8matrix (sint8 **m, long nrl, long nrh, long ncl, long nch); 50 IMAGE_EXPORT(void) resize_ui8matrix (uint8 **m, long nrl, long nrh, long ncl, long nch); 51 IMAGE_EXPORT(void) resize_si16matrix (sint16 **m, long nrl, long nrh, long ncl, long nch); 52 IMAGE_EXPORT(void) resize_ui16matrix (uint16 **m, long nrl, long nrh, long ncl, long nch); 53 IMAGE_EXPORT(void) resize_si32matrix (sint32 **m, long nrl, long nrh, long ncl, long nch); 54 IMAGE_EXPORT(void) resize_ui32matrix (uint32 **m, long nrl, long nrh, long ncl, long nch); 43 #undef resize_type_matrix 44 #define resize_type_matrix(t) \ 45 void short_name(t,resize_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); 55 46 56 IMAGE_EXPORT(void) resize_f32matrix (float32 **m, long nrl, long nrh, long ncl, long nch); 57 IMAGE_EXPORT(void) resize_f64matrix (float64 **m, long nrl, long nrh, long ncl, long nch); 47 resize_type_matrix(int8_t); 48 resize_type_matrix(uint8_t); 49 resize_type_matrix(int16_t); 50 resize_type_matrix(uint16_t); 51 resize_type_matrix(int32_t); 52 resize_type_matrix(uint32_t); 53 resize_type_matrix(int64_t); 54 resize_type_matrix(uint64_t); 55 resize_type_matrix(float); 56 resize_type_matrix(double); 57 resize_type_matrix(rgb8); 58 resize_type_matrix(rgbx8); 58 59 59 IMAGE_EXPORT(void) resize_rgb8matrix (rgb8 **m, long nrl, long nrh, long ncl, long nch);60 IMAGE_EXPORT(void) resize_rgbx8matrix(rgbx8 **m, long nrl, long nrh, long ncl, long nch);61 60 62 61 … … 67 66 */ 68 67 69 /* new versions UP */ 70 IMAGE_EXPORT(void) convert_si8matrix_si16matrix(sint8 **X, int nrl, int nrh, int ncl, int nch, sint16 **Y); 71 IMAGE_EXPORT(void) convert_si8matrix_si32matrix(sint8 **X, int nrl, int nrh, int ncl, int nch, sint32 **Y); 72 IMAGE_EXPORT(void) convert_si8matrix_f32matrix (sint8 **X, int nrl, int nrh, int ncl, int nch, float32 **Y); 73 IMAGE_EXPORT(void) convert_si8matrix_f64matrix (sint8 **X, int nrl, int nrh, int ncl, int nch, float64 **Y); 68 #define convert_type_matrix(t1,t2) \ 69 void short_name(t1,convert_,short_name(t2,matrix_,matrix))(t1 ** X, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t2 ** Y); 74 70 75 IMAGE_EXPORT(void) convert_ui8matrix_ui32matrix (uint8 **X, int nrl, int nrh, int ncl, int nch, uint32 **Y); 76 IMAGE_EXPORT(void) convert_ui8matrix_ui16matrix (uint8 **X, int nrl, int nrh, int ncl, int nch, uint16 **Y); 77 IMAGE_EXPORT(void) convert_ui8matrix_f32matrix (uint8 **X, int nrl, int nrh, int ncl, int nch, float32 **Y); 78 IMAGE_EXPORT(void) convert_ui8matrix_f64matrix (uint8 **X, int nrl, int nrh, int ncl, int nch, float64 **Y); 71 convert_type_matrix(int8_t,int16_t); 72 convert_type_matrix(int8_t,int32_t); 73 convert_type_matrix(int8_t,float); 74 convert_type_matrix(int8_t,double); 75 convert_type_matrix(uint8_t,uint16_t); 76 convert_type_matrix(uint8_t,uint32_t); 77 convert_type_matrix(uint8_t,float); 78 convert_type_matrix(uint8_t,double); 79 convert_type_matrix(uint8_t,rgb8); 80 convert_type_matrix(uint8_t,rgbx8); 81 convert_type_matrix(int16_t,int32_t); 82 convert_type_matrix(int16_t,float); 83 convert_type_matrix(int16_t,double); 84 convert_type_matrix(uint16_t,uint32_t); 85 convert_type_matrix(uint16_t,float); 86 convert_type_matrix(uint16_t,double); 87 convert_type_matrix(int32_t,float); 88 convert_type_matrix(int32_t,double); 89 convert_type_matrix(uint32_t,float); 90 convert_type_matrix(uint32_t,double); 79 91 80 IMAGE_EXPORT(void) convert_ui8matrix_rgb8matrix (uint8 **X, int nrl, int nrh, int ncl, int nch, rgb8 **Y); 81 IMAGE_EXPORT(void) convert_ui8matrix_rgbx8matrix(uint8 **X, int nrl, int nrh, int ncl, int nch, rgbx8 **Y); 82 83 IMAGE_EXPORT(void) convert_si16matrix_si32matrix(sint16 **X, int nrl, int nrh, int ncl, int nch, sint32 **Y); 84 IMAGE_EXPORT(void) convert_si16matrix_f32matrix (sint16 **X, int nrl, int nrh, int ncl, int nch, float32 **Y); 85 IMAGE_EXPORT(void) convert_si16matrix_f64matrix (sint16 **X, int nrl, int nrh, int ncl, int nch, float64 **Y); 86 87 IMAGE_EXPORT(void) convert_ui16matrix_ui32matrix(uint16 **X, int nrl, int nrh, int ncl, int nch, uint32 **Y); 88 IMAGE_EXPORT(void) convert_ui16matrix_f32matrix (uint16 **X, int nrl, int nrh, int ncl, int nch, float32 **Y); 89 IMAGE_EXPORT(void) convert_ui16matrix_f64matrix (uint16 **X, int nrl, int nrh, int ncl, int nch, float64 **Y); 90 91 IMAGE_EXPORT(void) convert_si32matrix_f32matrix (sint32 **X, int nrl, int nrh, int ncl, int nch, float32 **Y); 92 IMAGE_EXPORT(void) convert_si32matrix_f64matrix (sint32 **X, int nrl, int nrh, int ncl, int nch, float64 **Y); 93 94 IMAGE_EXPORT(void) convert_ui32matrix_f32matrix (uint32 **X, int nrl, int nrh, int ncl, int nch, float32 **Y); 95 IMAGE_EXPORT(void) convert_ui32matrix_f64matrix (uint32 **X, int nrl, int nrh, int ncl, int nch, float64 **Y); 92 convert_type_matrix(int16_t,int8_t); 93 convert_type_matrix(uint16_t,uint8_t); 94 convert_type_matrix(int32_t,int8_t); 95 convert_type_matrix(uint32_t,uint8_t); 96 convert_type_matrix(int32_t,int16_t); 97 convert_type_matrix(uint32_t,uint16_t); 98 convert_type_matrix(float,int8_t); 99 convert_type_matrix(float,uint8_t); 100 convert_type_matrix(float,int16_t); 101 convert_type_matrix(float,uint16_t); 102 convert_type_matrix(float,int32_t); 103 convert_type_matrix(float,uint32_t); 104 convert_type_matrix(double,int8_t); 105 convert_type_matrix(double,uint8_t); 106 convert_type_matrix(double,int16_t); 107 convert_type_matrix(double,uint16_t); 108 convert_type_matrix(double,int32_t); 109 convert_type_matrix(double,uint32_t); 110 convert_type_matrix(double,float); 111 convert_type_matrix(rgb8,uint8_t); 96 112 97 113 98 /* new versions DOWN */99 IMAGE_EXPORT(void) convert_ui16matrix_ui8matrix(uint16 **X, int nrl, int nrh, int ncl, int nch, uint8 **y);100 IMAGE_EXPORT(void) convert_si16matrix_si8matrix(sint16 **X, int nrl, int nrh, int ncl, int nch, sint8 **y);101 IMAGE_EXPORT(void) convert_ui32matrix_ui8matrix(uint32 **X, int nrl, int nrh, int ncl, int nch, uint8 **y);102 IMAGE_EXPORT(void) convert_si32matrix_si8matrix(sint32 **X, int nrl, int nrh, int ncl, int nch, sint8 **y);103 IMAGE_EXPORT(void) convert_f32matrix_ui8matrix (float32 **X, int nrl, int nrh, int ncl, int nch, uint8 **y);104 IMAGE_EXPORT(void) convert_f32matrix_si8matrix (float32 **X, int nrl, int nrh, int ncl, int nch, sint8 **y);105 106 IMAGE_EXPORT(void) convert_ui32matrix_ui16matrix(uint32 **X, int nrl, int nrh, int ncl, int nch, uint16 **y);107 IMAGE_EXPORT(void) convert_si32matrix_si16matrix(sint32 **X, int nrl, int nrh, int ncl, int nch, sint16 **y);108 IMAGE_EXPORT(void) convert_f32matrix_ui16matrix (float32 **X, int nrl, int nrh, int ncl, int nch, uint16 **y);109 IMAGE_EXPORT(void) convert_f32matrix_si16matrix (float32 **X, int nrl, int nrh, int ncl, int nch, sint16 **y);110 111 IMAGE_EXPORT(void) convert_f32matrix_ui32matrix (float32 **X, int nrl, int nrh, int ncl, int nch, uint32 **y);112 IMAGE_EXPORT(void) convert_f32matrix_si32matrix (float32 **X, int nrl, int nrh, int ncl, int nch, sint32 **y);113 114 114 115 /* … … 118 119 */ 119 120 120 IMAGE_EXPORT(void) lowpart_ui32matrix_ui8matrix (uint32 **X, long nrl,long nrh,long ncl, long nch, uint8 **Y); 121 IMAGE_EXPORT(void) lowpart_ui32matrix_ui16matrix(uint32 **X, long nrl,long nrh,long ncl, long nch, uint16 **Y); 121 void lowpart_ui16matrix_ui8matrix(uint16_t ** X, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, uint8_t ** Y); 122 void lowpart_ui32matrix_ui8matrix(uint32_t ** X, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, uint8_t ** Y); 123 122 124 123 125 /* … … 127 129 */ 128 130 129 IMAGE_EXPORT(void) split_rgb8matrix(rgb8 **X, long nrl, long nrh, long ncl, long nch, uint8 **R, uint8 **G, uint8 **B);130 IMAGE_EXPORT(void) merge_rgb8matrix(uint8 **R, uint8 **G, uint8 **B, long nrl, long nrh, long ncl, long nch, rgb8 **X);131 void split_rgb8matrix(rgb8 ** X, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, uint8_t ** R, uint8_t ** G, uint8_t ** B); 132 void merge_rgb8matrix(uint8_t ** R, uint8_t ** G, uint8_t ** B, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, rgb8 ** X); 131 133 134 #endif /* _NRMEM2_H_ */ 132 135 133 #ifdef __cplusplus 134 } 135 #endif 136 // Local Variables: 137 // tab-width: 4 138 // c-basic-offset: 4 139 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 140 // indent-tabs-mode: nil 141 // End: 136 142 137 #else 138 //#pragma message(" Warning : attemp to re-include nrmem2.h") 139 #endif /* _NRMEM2_H_ */ 143 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 144 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrmem2x.h
r772 r826 12 12 #define _NRMEM2X_H_ 13 13 14 #ifdef __cplusplus15 #ifdef PRAGMA_VERBOSE16 #pragma message ("C++")17 #endif18 extern "C" {19 #endif20 14 21 15 /* ------------------------------------------ */ … … 27 21 /* ------------------------------------------ */ 28 22 29 IMAGE_EXPORT(void) reset_endline_bmatrix (byte **m, long nrl, long nrh, long ncl, long nch); 30 IMAGE_EXPORT(void) reset_endline_i16matrix (int16 **m, long nrl, long nrh, long ncl, long nch); 31 IMAGE_EXPORT(void) reset_endline_ui16matrix(uint16 **m, long nrl, long nrh, long ncl, long nch); 32 IMAGE_EXPORT(void) reset_endline_imatrix (int **m, long nrl, long nrh, long ncl, long nch); 33 IMAGE_EXPORT(void) reset_endline_i32matrix (int32 **m, long nrl, long nrh, long ncl, long nch); 34 IMAGE_EXPORT(void) reset_endline_ui32matrix(uint32 **m, long nrl, long nrh, long ncl, long nch); 35 IMAGE_EXPORT(void) reset_endline_i64matrix (int64 **m, long nrl, long nrh, long ncl, long nch); 23 #define reset_endline_type_matrix(t) \ 24 void short_name(t,reset_endline_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); \ 25 void short_name(t,endline_,matrix)(t ** m, int32_t i, int32_t l); \ 26 void short_name(t,endline0_,matrix)(t ** m, int32_t i, int32_t l, int32_t ncl); \ 27 void short_name(t,endline1_,matrix)(t ** m, int32_t i, int32_t l, int32_t ncl); 36 28 37 IMAGE_EXPORT(void) endline_bmatrix (byte **m, long i, long l); 38 IMAGE_EXPORT(void) endline_i16matrix (int16 **m, long i, long l); 39 IMAGE_EXPORT(void) endline_ui16matrix(uint16 **m, long i, long l); 40 IMAGE_EXPORT(void) endline_imatrix (int **m, long i, long l); 41 IMAGE_EXPORT(void) endline_i32matrix (int32 **m, long i, long l); 42 IMAGE_EXPORT(void) endline_ui32matrix(uint32 **m, long i, long l); 43 IMAGE_EXPORT(void) endline_i64matrix (int64 **m, long i, long l); 29 reset_endline_type_matrix(int8_t); 30 reset_endline_type_matrix(uint8_t); 31 reset_endline_type_matrix(int16_t); 32 reset_endline_type_matrix(uint16_t); 33 reset_endline_type_matrix(int32_t); 34 reset_endline_type_matrix(uint32_t); 35 reset_endline_type_matrix(int64_t); 36 reset_endline_type_matrix(uint64_t); 44 37 45 IMAGE_EXPORT(void) endline0_bmatrix (byte **m, long i, long l, long ncl);46 IMAGE_EXPORT(void) endline0_i16matrix (int16 **m, long i, long l, long ncl);47 IMAGE_EXPORT(void) endline0_ui16matrix(uint16 **m, long i, long l, long ncl);48 IMAGE_EXPORT(void) endline0_imatrix (int **m, long i, long l, long ncl);49 IMAGE_EXPORT(void) endline0_i32matrix (int32 **m, long i, long l, long ncl);50 IMAGE_EXPORT(void) endline0_ui32matrix(uint32 **m, long i, long l, long ncl);51 IMAGE_EXPORT(void) endline0_i64matrix (int64 **m, long i, long l, long ncl);52 38 53 IMAGE_EXPORT(void) endline1_bmatrix (byte **m, long i, long l, long ncl); 54 IMAGE_EXPORT(void) endline1_i16matrix (int16 **m, long i, long l, long ncl); 55 IMAGE_EXPORT(void) endline1_ui16matrix(uint16 **m, long i, long l, long ncl); 56 IMAGE_EXPORT(void) endline1_imatrix (int **m, long i, long l, long ncl); 57 IMAGE_EXPORT(void) endline1_i32matrix (int32 **m, long i, long l, long ncl); 58 IMAGE_EXPORT(void) endline1_ui32matrix(uint32 **m, long i, long l, long ncl); 59 IMAGE_EXPORT(void) endline1_i64matrix (int64 **m, long i, long l, long ncl); 39 #undef resize_type_matrix 40 #define resize_type_matrix(t) \ 41 void short_name(t,resize_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); 60 42 61 IMAGE_EXPORT(void) resize_si16Pmatrix(si16Point **m, long nrl, long nrh, long ncl, long nch); 62 IMAGE_EXPORT(void) resize_ui16Pmatrix(ui16Point **m, long nrl, long nrh, long ncl, long nch); 63 IMAGE_EXPORT(void) resize_si32Pmatrix(si32Point **m, long nrl, long nrh, long ncl, long nch); 64 IMAGE_EXPORT(void) resize_ui32Pmatrix(ui32Point **m, long nrl, long nrh, long ncl, long nch); 65 IMAGE_EXPORT(void) resize_f32Pmatrix(f32Point **m, long nrl, long nrh, long ncl, long nch); 43 resize_type_matrix(si16Point); 44 resize_type_matrix(ui16Point); 45 resize_type_matrix(si32Point); 46 resize_type_matrix(ui32Point); 47 resize_type_matrix(f32Point); 48 resize_type_matrix(si16Triplet); 49 resize_type_matrix(ui16Triplet); 50 resize_type_matrix(si32Triplet); 51 resize_type_matrix(ui32Triplet); 52 resize_type_matrix(f32Triplet); 66 53 67 // Triplet Matrix 68 IMAGE_EXPORT(void) resize_si16Tmatrix(si16Triplet **m, long nrl, long nrh, long ncl, long nch); 69 IMAGE_EXPORT(void) resize_ui16Tmatrix(ui16Triplet **m, long nrl, long nrh, long ncl, long nch); 70 IMAGE_EXPORT(void) resize_si32Tmatrix(si32Triplet **m, long nrl, long nrh, long ncl, long nch); 71 IMAGE_EXPORT(void) resize_ui32Tmatrix(ui32Triplet **m, long nrl, long nrh, long ncl, long nch); 72 IMAGE_EXPORT(void) resize_f32Tmatrix (f32Triplet **m, long nrl, long nrh, long ncl, long nch); 54 55 #define type_matrix_reverse(t) \ 56 void short_name(t,,matrix_reverse)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); 57 58 type_matrix_reverse(int8_t); 59 type_matrix_reverse(uint8_t); 60 type_matrix_reverse(int16_t); 61 type_matrix_reverse(uint16_t); 62 type_matrix_reverse(int32_t); 63 type_matrix_reverse(uint32_t); 64 type_matrix_reverse(int64_t); 65 type_matrix_reverse(uint64_t); 66 type_matrix_reverse(float); 67 type_matrix_reverse(double); 73 68 74 69 75 70 71 #define desinterlace_type_matrix(t) \ 72 void short_name(t,desinterlace_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** D0, t ** D1); 76 73 77 /* 78 * -------------- 79 * matrix_reverse 80 * -------------- 81 */ 74 desinterlace_type_matrix(int8_t); 75 desinterlace_type_matrix(uint8_t); 76 desinterlace_type_matrix(int16_t); 77 desinterlace_type_matrix(uint16_t); 78 desinterlace_type_matrix(int32_t); 79 desinterlace_type_matrix(uint32_t); 80 desinterlace_type_matrix(int64_t); 81 desinterlace_type_matrix(uint64_t); 82 desinterlace_type_matrix(float); 83 desinterlace_type_matrix(double); 84 desinterlace_type_matrix(rgb8); 85 desinterlace_type_matrix(rgbx8); 82 86 83 //IMAGE_EXPORT(void) bmatrix_reverse (byte **m, long nrl, long nrh, long ncl, long nch);84 //IMAGE_EXPORT(void) si16matrix_reverse (sint16 **m, long nrl, long nrh, long ncl, long nch);85 //IMAGE_EXPORT(void) usmatrix_reverse(uint16 **m, long nrl, long nrh, long ncl, long nch);86 87 87 /* copie */ 88 IMAGE_EXPORT(void) copyc_bmatrix(byte **src,long nrl,long nrh,long ncl, long nch, byte **cond, byte c, byte **dst);88 #define interlace_type_matrix(t) \ 89 void short_name(t,interlace_,matrix)(t ** S0, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** S1, t ** D); 89 90 90 IMAGE_EXPORT(void) complete_border_bmatrix (byte **m, long nrl,long nrh,long ncl, long nch, long n); 91 IMAGE_EXPORT(void) complete_border1_bmatrix(byte **m, long nrl,long nrh,long ncl, long nch); 92 IMAGE_EXPORT(void) complete_border2_bmatrix(byte **m, long nrl,long nrh,long ncl, long nch); 91 interlace_type_matrix(int8_t); 92 interlace_type_matrix(uint8_t); 93 interlace_type_matrix(int16_t); 94 interlace_type_matrix(uint16_t); 95 interlace_type_matrix(int32_t); 96 interlace_type_matrix(uint32_t); 97 interlace_type_matrix(int64_t); 98 interlace_type_matrix(uint64_t); 99 interlace_type_matrix(float); 100 interlace_type_matrix(double); 101 interlace_type_matrix(rgb8); 102 interlace_type_matrix(rgbx8); 93 103 94 IMAGE_EXPORT(void) copy1c_bmatrix (byte **X, long nc, byte **Y, long nrl, long nrh, long ncl, long nch); 95 IMAGE_EXPORT(void) copy1c_si16matrix (sint16 **X, long nc, sint16 **Y, long nrl, long nrh, long ncl, long nch); 96 IMAGE_EXPORT(void) copy1c_ui16matrix (uint16 **X, long nc, uint16 **Y, long nrl, long nrh, long ncl, long nch); 97 IMAGE_EXPORT(void) copy1c_si32matrix (sint32 **X, long nc, sint32 **Y, long nrl, long nrh, long ncl, long nch); 98 IMAGE_EXPORT(void) copy1c_ui32matrix (uint32 **X, long nc, uint32 **Y, long nrl, long nrh, long ncl, long nch); 99 IMAGE_EXPORT(void) copy1c_f32matrix (float32 **X, long nc, float32 **Y, long nrl, long nrh, long ncl, long nch); 100 IMAGE_EXPORT(void) copy1c_f64matrix (float64 **X, long nc, float64 **Y, long nrl, long nrh, long ncl, long nch); 101 IMAGE_EXPORT(void) copy1c_rgb8matrix (rgb8 **X, long nc, rgb8 **Y, long nrl, long nrh, long ncl, long nch); 102 IMAGE_EXPORT(void) copy1c_rgbx8matrix(rgbx8 **X, long nc, rgbx8 **Y, long nrl, long nrh, long ncl, long nch); 104 105 #define copyc_type_matrix(t) \ 106 void short_name(t,copyc_,matrix)(t ** src, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** cond, t c, t ** dst) \ 103 107 104 108 /* … … 106 110 * dst(i,j) = src(i,j) si cond(i,j) == c 107 111 */ 108 /*109 IMAGE_EXPORT(void) copy1r_bmatrix (byte **X, long nr, byte **Y, long nrl, long nrh, long ncl, long nch);110 IMAGE_EXPORT(void) copy1r_smatrix (sint16 **X, long nr, sint16 **Y, long nrl, long nrh, long ncl, long nch);111 IMAGE_EXPORT(void) copy1r_usmatrix (uint16 **X, long nr, uint16 **Y, long nrl, long nrh, long ncl, long nch);112 IMAGE_EXPORT(void) copy1r_imatrix (int **X, long nr, int **Y, long nrl, long nrh, long ncl, long nch);113 IMAGE_EXPORT(void) copy1r_uimatrix (uint **X, long nr, uint **Y, long nrl, long nrh, long ncl, long nch);114 IMAGE_EXPORT(void) copy1r_matrix (float **X, long nr, float **Y, long nrl, long nrh, long ncl, long nch);115 IMAGE_EXPORT(void) copy1r_dmatrix (double **X, long nr, double **Y, long nrl, long nrh, long ncl, long nch);116 IMAGE_EXPORT(void) copy1r_rgb8matrix (rgb8 **X, long nr, rgb8 **Y, long nrl, long nrh, long ncl, long nch);117 IMAGE_EXPORT(void) copy1r_rgbx8matrix(rgbx8 **X, long nr, rgbx8 **Y, long nrl, long nrh, long ncl, long nch);118 112 119 IMAGE_EXPORT(void) copy_bmatrix (byte **m1, long nrl1,long nrh1,long ncl1, long nch1, byte **m2, long nrl2, long nrh2, long ncl2, long nch2); 120 IMAGE_EXPORT(void) copy_smatrix (sint16 **m1, long nrl1,long nrh1,long ncl1, long nch1, sint16 **m2, long nrl2, long nrh2, long ncl2, long nch2); 121 IMAGE_EXPORT(void) copy_usmatrix (uint16 **m1, long nrl1,long nrh1,long ncl1, long nch1, uint16 **m2, long nrl2, long nrh2, long ncl2, long nch2); 122 IMAGE_EXPORT(void) copy_imatrix (int **m1, long nrl1,long nrh1,long ncl1, long nch1, int **m2, long nrl2, long nrh2, long ncl2, long nch2); 123 IMAGE_EXPORT(void) copy_uimatrix (uint **m1, long nrl1,long nrh1,long ncl1, long nch1, uint **m2, long nrl2, long nrh2, long ncl2, long nch2); 124 IMAGE_EXPORT(void) copy_matrix (float **m1, long nrl1,long nrh1,long ncl1, long nch1, float **m2, long nrl2, long nrh2, long ncl2, long nch2); 125 IMAGE_EXPORT(void) copy_dmatrix (double **m1, long nrl1,long nrh1,long ncl1, long nch1, double **m2, long nrl2, long nrh2, long ncl2, long nch2); 126 IMAGE_EXPORT(void) copy_rgb8matrix (rgb8 **m1, long nrl1,long nrh1,long ncl1, long nch1, rgb8 **m2, long nrl2, long nrh2, long ncl2, long nch2); 127 IMAGE_EXPORT(void) copy_rgbx8matrix(rgbx8 **m1, long nrl1,long nrh1,long ncl1, long nch1, rgbx8 **m2, long nrl2, long nrh2, long ncl2, long nch2); 128 129 IMAGE_EXPORT(void) copy_sub_bmatrix(byte **src, long nrl,long nrh,long ncl, long nch, byte **dst); 130 131 IMAGE_EXPORT(void) extract_bmatrix (byte **src, long nrl,long nrh,long ncl, long nch, byte **dst); 132 IMAGE_EXPORT(void) extract_smatrix (sint16 **src, long nrl,long nrh,long ncl, long nch, sint16 **dst); 133 IMAGE_EXPORT(void) extract_usmatrix(uint16 **src, long nrl,long nrh,long ncl, long nch, uint16 **dst); 134 IMAGE_EXPORT(void) extract_imatrix (int **src, long nrl,long nrh,long ncl, long nch, int **dst); 135 IMAGE_EXPORT(void) extract_uimatrix(uint **src, long nrl,long nrh,long ncl, long nch, uint **dst); 136 IMAGE_EXPORT(void) extract_matrix (float **src, long nrl,long nrh,long ncl, long nch, float **dst); 137 IMAGE_EXPORT(void) extract_dmatrix (double **src, long nrl,long nrh,long ncl, long nch, double **dst); 138 */ 139 IMAGE_EXPORT(void) copy_center_bmatrix(byte **src, long nrl0,long nrh0,long ncl0, long nch0, byte **dst, long nrl1,long nrh1,long ncl1, long nch1); 140 141 IMAGE_EXPORT(void) copy_sub_imatrix(int **src, long nrl,long nrh,long ncl, long nch, int **dst); 142 143 IMAGE_EXPORT(void) copy_sub_imatrix_index(int **src, long nrl,long nrh, long ncl, long nch, int **dst,int *index); 144 145 /* --------------------- */ 146 /* --- De-Interleave --- */ 147 /* --------------------- */ 148 149 IMAGE_EXPORT(void) desinterlace_bmatrix (byte **S, long nrl, long nrh, long ncl, long nch, byte **D0, byte **D1); 150 IMAGE_EXPORT(void) desinterlace_rgb8matrix(rgb8 **S, long nrl, long nrh, long ncl, long nch, rgb8 **D0, rgb8 **D1); 151 152 IMAGE_EXPORT(void) interlace_bmatrix (byte **S0, long nrl, long nrh, long ncl, long nch, byte **S1, byte **D); 153 IMAGE_EXPORT(void) interlace_rgb8matrix(rgb8 **S0, long nrl, long nrh, long ncl, long nch, rgb8 **S1, rgb8 **D); 113 copyc_type_matrix(int8_t); 114 copyc_type_matrix(uint8_t); 115 copyc_type_matrix(int16_t); 116 copyc_type_matrix(uint16_t); 117 copyc_type_matrix(int32_t); 118 copyc_type_matrix(uint32_t); 119 copyc_type_matrix(int64_t); 120 copyc_type_matrix(uint64_t); 121 copyc_type_matrix(float); 122 copyc_type_matrix(double); 123 copyc_type_matrix(rgb8); 124 copyc_type_matrix(rgbx8); 154 125 155 126 156 #ifdef __cplusplus 157 } 158 #endif 127 #define complete_border_type_matrix(t) \ 128 void short_name(t,complete_border_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t n); \ 129 void short_name(t,complete_border1_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); \ 130 void short_name(t,complete_border2_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); 159 131 160 #else 161 //#pragma message(" Warning : attemp to re-include nrmem2x.h") 132 complete_border_type_matrix(int8_t); 133 complete_border_type_matrix(uint8_t); 134 complete_border_type_matrix(int16_t); 135 complete_border_type_matrix(uint16_t); 136 complete_border_type_matrix(int32_t); 137 complete_border_type_matrix(uint32_t); 138 complete_border_type_matrix(int64_t); 139 complete_border_type_matrix(uint64_t); 140 complete_border_type_matrix(float); 141 complete_border_type_matrix(double); 142 complete_border_type_matrix(rgb8); 143 complete_border_type_matrix(rgbx8); 144 145 146 #define copy1c_type_matrix(t) \ 147 void short_name(t,copy1c_,matrix)(t ** X, int32_t nc, t ** Y, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); \ 148 void short_name(t,copy1r_,matrix)(t ** X, int32_t nr, t ** Y, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); 149 150 copy1c_type_matrix(int8_t); 151 copy1c_type_matrix(uint8_t); 152 copy1c_type_matrix(int16_t); 153 copy1c_type_matrix(uint16_t); 154 copy1c_type_matrix(int32_t); 155 copy1c_type_matrix(uint32_t); 156 copy1c_type_matrix(int64_t); 157 copy1c_type_matrix(uint64_t); 158 copy1c_type_matrix(float); 159 copy1c_type_matrix(double); 160 copy1c_type_matrix(rgb8); 161 copy1c_type_matrix(rgbx8); 162 163 162 164 #endif /* _NRMEM2X_H_ */ 165 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrmem2xx.h
r772 r826 8 8 #define _NRMEM2XX_H_ 9 9 10 #ifdef __cplusplus11 #ifdef PRAGMA_VERBOSE12 #pragma message ("C++")13 #endif14 extern "C" {15 #endif16 10 17 11 /* ----------------------- */ 18 12 /* -- Rotation and Flip -- */ 19 13 /* ----------------------- */ 14 20 15 // no check performed on size, S and D must be different 21 IMAGE_EXPORT(void) lrotate_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch, byte **D);22 IMAGE_EXPORT(void) lrotate_smatrix (short **S, long nrl,long nrh,long ncl, long nch, short **D);23 IMAGE_EXPORT(void) lrotate_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch, ushort **D);24 IMAGE_EXPORT(void) lrotate_si16matrix(sint16 **S, long nrl,long nrh,long ncl, long nch, sint16 **D);25 IMAGE_EXPORT(void) lrotate_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch, uint16 **D);26 IMAGE_EXPORT(void) lrotate_imatrix (int **S, long nrl,long nrh,long ncl, long nch, int **D);27 IMAGE_EXPORT(void) lrotate_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch, uint **D);28 IMAGE_EXPORT(void) lrotate_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch, int32 **D);29 IMAGE_EXPORT(void) lrotate_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch, uint32 **D);30 IMAGE_EXPORT(void) lrotate_matrix (float **S, long nrl,long nrh,long ncl, long nch, float **D);31 IMAGE_EXPORT(void) lrotate_dmatrix (double **S, long nrl,long nrh,long ncl, long nch, double **D);32 IMAGE_EXPORT(void) lrotate_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch, rgb8 **D);33 16 34 IMAGE_EXPORT(void) rrotate_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch, byte **D);35 IMAGE_EXPORT(void) rrotate_smatrix (short **S, long nrl,long nrh,long ncl, long nch, short **D);36 IMAGE_EXPORT(void) rrotate_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch, ushort **D);37 IMAGE_EXPORT(void) rrotate_si16matrix(sint16 **S, long nrl,long nrh,long ncl, long nch, sint16 **D);38 IMAGE_EXPORT(void) rrotate_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch, uint16 **D);39 IMAGE_EXPORT(void) rrotate_imatrix (int **S, long nrl,long nrh,long ncl, long nch, int **D);40 IMAGE_EXPORT(void) rrotate_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch, uint **D);41 IMAGE_EXPORT(void) rrotate_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch, int32 **D);42 IMAGE_EXPORT(void) rrotate_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch, uint32 **D);43 IMAGE_EXPORT(void) rrotate_matrix (float **S, long nrl,long nrh,long ncl, long nch, float **D);44 IMAGE_EXPORT(void) rrotate_dmatrix (double **S, long nrl,long nrh,long ncl, long nch, double **D);45 IMAGE_EXPORT(void) rrotate_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch, rgb8 **D);46 17 47 IMAGE_EXPORT(void) lrotate1_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch); 48 IMAGE_EXPORT(void) lrotate1_smatrix (short **S, long nrl,long nrh,long ncl, long nch); 49 IMAGE_EXPORT(void) lrotate1_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch); 50 IMAGE_EXPORT(void) lrotate1_si16matrix(sint16 **S, long nrl,long nrh,long ncl, long nch); 51 IMAGE_EXPORT(void) lrotate1_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch); 52 IMAGE_EXPORT(void) lrotate1_imatrix (int **S, long nrl,long nrh,long ncl, long nch); 53 IMAGE_EXPORT(void) lrotate1_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch); 54 IMAGE_EXPORT(void) lrotate1_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch); 55 IMAGE_EXPORT(void) lrotate1_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch); 56 IMAGE_EXPORT(void) lrotate1_matrix (float **S, long nrl,long nrh,long ncl, long nch); 57 IMAGE_EXPORT(void) lrotate1_dmatrix (double **S, long nrl,long nrh,long ncl, long nch); 58 IMAGE_EXPORT(void) lrotate1_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch); 18 #define rotate_flip_type_matrix(t) \ 19 void short_name(t,lrotate_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** D); \ 20 void short_name(t,rrotate_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** D); \ 21 void short_name(t,lrotate1_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); \ 22 void short_name(t,rrotate1_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); \ 23 void short_name(t,hflip_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** D); \ 24 void short_name(t,vflip_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, t ** D); \ 25 void short_name(t,hflip1_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); \ 26 void short_name(t,vflip1_,matrix)(t ** S, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); 59 27 60 IMAGE_EXPORT(void) rrotate1_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch);61 IMAGE_EXPORT(void) rrotate1_smatrix (short **S, long nrl,long nrh,long ncl, long nch);62 IMAGE_EXPORT(void) rrotate1_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch);63 IMAGE_EXPORT(void) rrotate1_si16matrix(sint16 **S, long nrl,long nrh,long ncl, long nch);64 IMAGE_EXPORT(void) rrotate1_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch);65 IMAGE_EXPORT(void) rrotate1_imatrix (int **S, long nrl,long nrh,long ncl, long nch);66 IMAGE_EXPORT(void) rrotate1_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch);67 IMAGE_EXPORT(void) rrotate1_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch);68 IMAGE_EXPORT(void) rrotate1_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch);69 IMAGE_EXPORT(void) rrotate1_matrix (float **S, long nrl,long nrh,long ncl, long nch);70 IMAGE_EXPORT(void) rrotate1_dmatrix (double **S, long nrl,long nrh,long ncl, long nch);71 IMAGE_EXPORT(void) rrotate1_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch);28 rotate_flip_type_matrix(int8_t); 29 rotate_flip_type_matrix(uint8_t); 30 rotate_flip_type_matrix(int16_t); 31 rotate_flip_type_matrix(uint16_t); 32 rotate_flip_type_matrix(int32_t); 33 rotate_flip_type_matrix(uint32_t); 34 rotate_flip_type_matrix(int64_t); 35 rotate_flip_type_matrix(uint64_t); 36 rotate_flip_type_matrix(float); 37 rotate_flip_type_matrix(double); 38 rotate_flip_type_matrix(rgb8); 39 rotate_flip_type_matrix(rgbx8); 72 40 73 IMAGE_EXPORT(void) hflip_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch, byte **D);74 IMAGE_EXPORT(void) hflip_smatrix (short **S, long nrl,long nrh,long ncl, long nch, short **D);75 IMAGE_EXPORT(void) hflip_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch, ushort **D);76 IMAGE_EXPORT(void) hflip_i16matrix (int16 **S, long nrl,long nrh,long ncl, long nch, int16 **D);77 IMAGE_EXPORT(void) hflip_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch, uint16 **D);78 IMAGE_EXPORT(void) hflip_imatrix (int **S, long nrl,long nrh,long ncl, long nch, int **D);79 IMAGE_EXPORT(void) hflip_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch, uint **D);80 IMAGE_EXPORT(void) hflip_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch, int32 **D);81 IMAGE_EXPORT(void) hflip_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch, uint32 **D);82 IMAGE_EXPORT(void) hflip_matrix (float **S, long nrl,long nrh,long ncl, long nch, float **D);83 IMAGE_EXPORT(void) hflip_dmatrix (double **S, long nrl,long nrh,long ncl, long nch, double **D);84 IMAGE_EXPORT(void) hflip_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch, rgb8 **D);85 41 86 IMAGE_EXPORT(void) vflip_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch, byte **D); 87 IMAGE_EXPORT(void) vflip_smatrix (short **S, long nrl,long nrh,long ncl, long nch, short **D); 88 IMAGE_EXPORT(void) vflip_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch, ushort **D); 89 IMAGE_EXPORT(void) vflip_si16matrix(sint16 **S, long nrl,long nrh,long ncl, long nch, int16 **D); 90 IMAGE_EXPORT(void) vflip_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch, uint16 **D); 91 IMAGE_EXPORT(void) vflip_imatrix (int **S, long nrl,long nrh,long ncl, long nch, int **D); 92 IMAGE_EXPORT(void) vflip_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch, uint **D); 93 IMAGE_EXPORT(void) vflip_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch, int32 **D); 94 IMAGE_EXPORT(void) vflip_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch, uint32 **D); 95 IMAGE_EXPORT(void) vflip_matrix (float **S, long nrl,long nrh,long ncl, long nch, float **D); 96 IMAGE_EXPORT(void) vflip_dmatrix (double **S, long nrl,long nrh,long ncl, long nch, double **D); 97 IMAGE_EXPORT(void) vflip_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch, rgb8 **D); 42 #endif /* _NRMEM2XX_H_ */ 98 43 99 IMAGE_EXPORT(void) hflip1_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch); 100 IMAGE_EXPORT(void) hflip1_smatrix (short **S, long nrl,long nrh,long ncl, long nch); 101 IMAGE_EXPORT(void) hflip1_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch); 102 IMAGE_EXPORT(void) hflip1_si16matrix(sint16 **S, long nrl,long nrh,long ncl, long nch); 103 IMAGE_EXPORT(void) hflip1_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch); 104 IMAGE_EXPORT(void) hflip1_imatrix (int **S, long nrl,long nrh,long ncl, long nch); 105 IMAGE_EXPORT(void) hflip1_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch); 106 IMAGE_EXPORT(void) hflip1_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch); 107 IMAGE_EXPORT(void) hflip1_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch); 108 IMAGE_EXPORT(void) hflip1_matrix (float **S, long nrl,long nrh,long ncl, long nch); 109 IMAGE_EXPORT(void) hflip1_dmatrix (double **S, long nrl,long nrh,long ncl, long nch); 110 IMAGE_EXPORT(void) hflip1_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch); 44 // Local Variables: 45 // tab-width: 4 46 // c-basic-offset: 4 47 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 48 // indent-tabs-mode: nil 49 // End: 111 50 112 IMAGE_EXPORT(void) vflip1_bmatrix (byte **S, long nrl,long nrh,long ncl, long nch); 113 IMAGE_EXPORT(void) vflip1_smatrix (short **S, long nrl,long nrh,long ncl, long nch); 114 IMAGE_EXPORT(void) vflip1_usmatrix (ushort **S, long nrl,long nrh,long ncl, long nch); 115 IMAGE_EXPORT(void) vflip1_si16matrix(sint16 **S, long nrl,long nrh,long ncl, long nch); 116 IMAGE_EXPORT(void) vflip1_ui16matrix(uint16 **S, long nrl,long nrh,long ncl, long nch); 117 IMAGE_EXPORT(void) vflip1_imatrix (int **S, long nrl,long nrh,long ncl, long nch); 118 IMAGE_EXPORT(void) vflip1_uimatrix (uint **S, long nrl,long nrh,long ncl, long nch); 119 IMAGE_EXPORT(void) vflip1_i32matrix (int32 **S, long nrl,long nrh,long ncl, long nch); 120 IMAGE_EXPORT(void) vflip1_ui32matrix(uint32 **S, long nrl,long nrh,long ncl, long nch); 121 IMAGE_EXPORT(void) vflip1_matrix (float **S, long nrl,long nrh,long ncl, long nch); 122 IMAGE_EXPORT(void) vflip1_dmatrix (double **S, long nrl,long nrh,long ncl, long nch); 123 IMAGE_EXPORT(void) vflip1_rgb8matrix(rgb8 **S, long nrl,long nrh,long ncl, long nch); 51 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 124 52 125 #ifdef __cplusplus126 }127 #endif128 129 #else130 //#pragma message(" Warning : attemp to re-include nrmem2x.h")131 #endif /* _NRMEM2XX_H_ */ -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrset1.h
r772 r826 11 11 #define _NRSET1_H_ 12 12 13 #ifdef __cplusplus14 #ifdef PRAGMA_VERBOSE15 #pragma message ("C++")16 #endif17 extern "C" {18 #endif19 20 #ifdef PRAGMA_VERBOSE21 //#pragma message("- include nrset1.h")22 #endif23 13 24 14 /* 25 15 * ------------ 26 16 * --- Zero --- 17 * --- set_vector --- 18 * --- set_vector_param --- 19 * --- set_vector_j --- 27 20 * ------------ 28 21 */ 29 22 30 IMAGE_EXPORT(void) zero_si8vector (sint8 *v, long nl, long nh); 31 IMAGE_EXPORT(void) zero_ui8vector (uint8 *v, long nl, long nh); 32 IMAGE_EXPORT(void) zero_si16vector (sint16 *v, long nl, long nh); 33 IMAGE_EXPORT(void) zero_ui16vector (uint16 *v, long nl, long nh); 34 IMAGE_EXPORT(void) zero_si32vector (sint32 *v, long nl, long nh); 35 IMAGE_EXPORT(void) zero_ui32vector (uint32 *v, long nl, long nh); 36 IMAGE_EXPORT(void) zero_si64vector (sint64 *v, long nl, long nh); 37 IMAGE_EXPORT(void) zero_ui64vector (uint64 *v, long nl, long nh); 23 #define zero_set_type_vector(t) \ 24 void short_name(t,zero_,vector)(t * v, int32_t nl, int32_t nh); \ 25 void short_name(t,set_,vector)(t * v, int32_t nl, int32_t nh, t x); \ 26 void short_name(t,set_,vector_param)(t * v, int32_t nl, int32_t nh, t x, t xstep); \ 27 void short_name(t,set_,vector_j)(t * v, int32_t nl, int32_t nh); 38 28 39 IMAGE_EXPORT(void) zero_f32vector (float32 *v, long nl, long nh); 40 IMAGE_EXPORT(void) zero_f64vector (float64 *v, long nl, long nh); 29 zero_set_type_vector(int8_t); 30 zero_set_type_vector(uint8_t); 31 zero_set_type_vector(int16_t); 32 zero_set_type_vector(uint16_t); 33 zero_set_type_vector(int32_t); 34 zero_set_type_vector(uint32_t); 35 zero_set_type_vector(int64_t); 36 zero_set_type_vector(uint64_t); 37 zero_set_type_vector(float); 38 zero_set_type_vector(double); 39 zero_set_type_vector(rgb8); 40 zero_set_type_vector(rgbx8); 41 41 42 IMAGE_EXPORT(void) zero_rgb8vector (rgb8 *v, long nl, long nh);43 IMAGE_EXPORT(void) zero_rgbx8vector(rgbx8 *v, long nl, long nh);44 45 /*46 * ------------------47 * --- set_vector ---48 * ------------------49 */50 51 IMAGE_EXPORT(void) set_si8vector (sint8 *v, long nl, long nh, sint8 x);52 IMAGE_EXPORT(void) set_ui8vector (uint8 *v, long nl, long nh, uint8 x);53 IMAGE_EXPORT(void) set_si16vector (sint16 *v, long nl, long nh, int16 x);54 IMAGE_EXPORT(void) set_ui16vector (uint16 *v, long nl, long nh, uint16 x);55 IMAGE_EXPORT(void) set_si32vector (sint32 *v, long nl, long nh, sint32 x);56 IMAGE_EXPORT(void) set_ui32vector (uint32 *v, long nl, long nh, uint32 x);57 IMAGE_EXPORT(void) set_si64vector (sint64 *v, long nl, long nh, sint64 x);58 IMAGE_EXPORT(void) set_ui64vector (uint64 *v, long nl, long nh, uint64 x);59 60 IMAGE_EXPORT(void) set_f32vector (float32 *v, long nl, long nh, float32 x);61 IMAGE_EXPORT(void) set_f64vector (float64 *v, long nl, long nh, float64 x);62 63 IMAGE_EXPORT(void) set_rgb8vector (rgb8 *v, long nl, long nh, rgb8 x);64 IMAGE_EXPORT(void) set_rgbx8vector(rgbx8 *v, long nl, long nh, rgbx8 x);65 66 /*67 * ------------------------68 * --- set_vector_param ---69 * ------------------------70 */71 72 IMAGE_EXPORT(void) set_si8vector_param (sint8 *v, long nl, long nh, sint8 x, sint8 xstep);73 IMAGE_EXPORT(void) set_ui8vector_param (uint8 *v, long nl, long nh, uint8 x, uint8 xstep);74 IMAGE_EXPORT(void) set_si16vector_param (sint16 *v, long nl, long nh, int16 x, sint16 xstep);75 IMAGE_EXPORT(void) set_ui16vector_param (uint16 *v, long nl, long nh, uint16 x, uint16 xstep);76 IMAGE_EXPORT(void) set_si32vector_param (sint32 *v, long nl, long nh, sint32 x, sint32 xstep);77 IMAGE_EXPORT(void) set_ui32vector_param (uint32 *v, long nl, long nh, uint32 x, uint32 xstep);78 IMAGE_EXPORT(void) set_si64vector_param (sint64 *v, long nl, long nh, sint64 x, sint64 xstep);79 IMAGE_EXPORT(void) set_ui64vector_param (uint64 *v, long nl, long nh, uint64 x, uint64 xstep);80 81 IMAGE_EXPORT(void) set_f32vector_param (float32 *v, long nl, long nh, float32 x, float32 xstep);82 IMAGE_EXPORT(void) set_f64vector_param (float64 *v, long nl, long nh, float64 x, float64 xstep);83 84 IMAGE_EXPORT(void) set_rgb8vector_param (rgb8 *v, long nl, long nh, rgb8 x, rgb8 xstep);85 IMAGE_EXPORT(void) set_rgbx8vector_param(rgbx8 *v, long nl, long nh, rgbx8 x, rgbx8 xstep);86 87 /*88 * --------------------89 * --- set_vector_j ---90 * --------------------91 */92 93 IMAGE_EXPORT(void) set_si8vector_j (sint8 *v, long nl, long nh);94 IMAGE_EXPORT(void) set_ui8vector_j (uint8 *v, long nl, long nh);95 IMAGE_EXPORT(void) set_si16vector_j (sint16 *v, long nl, long nh);96 IMAGE_EXPORT(void) set_ui16vector_j (uint16 *v, long nl, long nh);97 IMAGE_EXPORT(void) set_si32vector_j (sint32 *v, long nl, long nh);98 IMAGE_EXPORT(void) set_ui32vector_j (uint32 *v, long nl, long nh);99 100 IMAGE_EXPORT(void) set_f32vector_j (float32 *v, long nl, long nh);101 IMAGE_EXPORT(void) set_f64vector_j (float64 *v, long nl, long nh);102 103 IMAGE_EXPORT(void) set_rgb8vector_j (rgb8 *v, long nl, long nh);104 IMAGE_EXPORT(void) set_rgbx8vector_j(rgbx8 *v, long nl, long nh);105 42 106 43 /* … … 110 47 */ 111 48 112 IMAGE_EXPORT(void) set_si8vector_str (sint8 *v, long nl, long nh, char *str); 113 IMAGE_EXPORT(void) set_ui8vector_str (uint8 *v, long nl, long nh, char *str); 114 IMAGE_EXPORT(void) set_si16vector_str (sint16 *v, long nl, long nh, char *str); 115 IMAGE_EXPORT(void) set_ui16vector_str (uint16 *v, long nl, long nh, char *str); 116 IMAGE_EXPORT(void) set_si32vector_str (sint32 *v, long nl, long nh, char *str); 117 IMAGE_EXPORT(void) set_ui32vector_str (uint32 *v, long nl, long nh, char *str); 49 #define set_type_vector_str(t) \ 50 void short_name(t,set_,vector_str)(t * v, int32_t nl, int32_t nh, char * str); 118 51 119 #ifdef __cplusplus 120 } 121 #endif 52 set_type_vector_str(int8_t); 53 set_type_vector_str(uint8_t); 54 set_type_vector_str(int16_t); 55 set_type_vector_str(uint16_t); 56 set_type_vector_str(int32_t); 57 set_type_vector_str(uint32_t); 58 set_type_vector_str(int64_t); 59 set_type_vector_str(uint64_t); 60 122 61 123 62 #endif /* __NRSET1_H__ */ 63 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrset2.h
r772 r826 11 11 #define _NR_SET2_H_ 12 12 13 #ifdef __cplusplus14 #ifdef PRAGMA_VERBOSE15 #pragma message ("C++")16 #endif17 extern "C" {18 #endif19 13 20 #ifdef PRAGMA_VERBOSE 21 //#pragma message("- include nrset2.h") 22 #endif 23 24 IMAGE_EXPORT(void) zero_si8matrix (sint8 **m, int i0,int i1,int j0,int j1); 25 IMAGE_EXPORT(void) zero_ui8matrix (uint8 **m, int i0,int i1,int j0,int j1); 26 IMAGE_EXPORT(void) zero_si16matrix (sint16 **m, int i0,int i1,int j0,int j1); 27 IMAGE_EXPORT(void) zero_ui16matrix (uint16 **m, int i0,int i1,int j0,int j1); 28 IMAGE_EXPORT(void) zero_si32matrix (sint32 **m, int i0,int i1,int j0,int j1); 29 IMAGE_EXPORT(void) zero_ui32matrix (uint32 **m, int i0,int i1,int j0,int j1); 30 IMAGE_EXPORT(void) zero_si64matrix (sint64 **m, int i0,int i1,int j0,int j1); 31 IMAGE_EXPORT(void) zero_ui64matrix (uint64 **m, int i0,int i1,int j0,int j1); 32 33 IMAGE_EXPORT(void) zero_f32matrix (float32 **m, int i0,int i1,int j0,int j1); 34 IMAGE_EXPORT(void) zero_f64matrix (float64 **m, int i0,int i1,int j0,int j1); 35 36 IMAGE_EXPORT(void) zero_rgb8matrix (rgb8 **m, int i0,int i1,int j0,int j1); 37 IMAGE_EXPORT(void) zero_rgbx8matrix(rgbx8 **m, int i0,int i1,int j0,int j1); 38 39 /* ------------------ */ 40 /* --- set_matrix --- */ 41 /* ------------------ */ 42 43 IMAGE_EXPORT(void) set_si8matrix (sint8 **m,int i0,int i1,int j0, int j1, sint8 x); 44 IMAGE_EXPORT(void) set_ui8matrix (uint8 **m,int i0,int i1,int j0, int j1, uint8 x); 45 IMAGE_EXPORT(void) set_si16matrix (sint16 **m,int i0,int i1,int j0, int j1, sint16 x); 46 IMAGE_EXPORT(void) set_ui16matrix (uint16 **m,int i0,int i1,int j0, int j1, uint16 x); 47 IMAGE_EXPORT(void) set_si32matrix (sint32 **m,int i0,int i1,int j0, int j1, sint32 x); 48 IMAGE_EXPORT(void) set_ui32matrix (uint32 **m,int i0,int i1,int j0, int j1, uint32 x); 49 IMAGE_EXPORT(void) set_si64matrix (sint64 **m,int i0,int i1,int j0, int j1, sint64 x); 50 IMAGE_EXPORT(void) set_ui64matrix (uint64 **m,int i0,int i1,int j0, int j1, uint64 x); 51 52 IMAGE_EXPORT(void) set_f32matrix (float32 **m,int i0,int i1,int j0, int j1, float32 x); 53 IMAGE_EXPORT(void) set_f64matrix (float64 **m,int i0,int i1,int j0, int j1, float64 x); 54 55 IMAGE_EXPORT(void) set_rgb8matrix (rgb8 **m,int i0,int i1,int j0, int j1, rgb8 x); 56 IMAGE_EXPORT(void) set_rgbx8matrix(rgbx8 **m,int i0,int i1,int j0, int j1, rgbx8 x); 57 58 /* 59 * ------------------------ 14 /* ------------------ 15 * --- set_matrix --- 60 16 * --- set_matrix_param --- 61 * ------------------ ------17 * ------------------ 62 18 */ 63 64 IMAGE_EXPORT(void) set_si8matrix_param (sint8 **m, int i0, int i1, int j0, int j1, sint8 x, sint8 xstep, sint8 ystep);65 IMAGE_EXPORT(void) set_ui8matrix_param (uint8 **m, int i0, int i1, int j0, int j1, uint8 x, uint8 xstep, uint8 ystep);66 IMAGE_EXPORT(void) set_si16matrix_param (sint16 **m, int i0, int i1, int j0, int j1, sint16 x, sint16 xstep, sint16 ystep);67 IMAGE_EXPORT(void) set_ui16matrix_param (uint16 **m, int i0, int i1, int j0, int j1, uint16 x, uint16 xstep, uint16 ystep);68 IMAGE_EXPORT(void) set_si32matrix_param (sint32 **m, int i0, int i1, int j0, int j1, sint32 x, sint32 xstep, sint32 ystep);69 IMAGE_EXPORT(void) set_ui32matrix_param (uint32 **m, int i0, int i1, int j0, int j1, uint32 x, uint32 xstep, uint32 ystep);70 IMAGE_EXPORT(void) set_si64matrix_param (sint64 **m, int i0, int i1, int j0, int j1, sint64 x, sint64 xstep, sint64 ystep);71 IMAGE_EXPORT(void) set_ui64matrix_param (uint64 **m, int i0, int i1, int j0, int j1, uint64 x, uint64 xstep, uint64 ystep);72 73 IMAGE_EXPORT(void) set_f32matrix_param (float32 **m, int i0, int i1, int j0, int j1, float32 x, float32 xstep, float32 ystep);74 IMAGE_EXPORT(void) set_f64matrix_param (float64 **m, int i0, int i1, int j0, int j1, float64 x, float64 xstep, float64 ystep);75 76 IMAGE_EXPORT(void) set_rgb8matrix_param (rgb8 **m, int i0, int i1, int j0, int j1, rgb8 x, rgb8 xstep, rgb8 ystep);77 IMAGE_EXPORT(void) set_rgbx8matrix_param(rgbx8 **m, int i0, int i1, int j0, int j1, rgbx8 x, rgbx8 xstep, rgbx8 ystep);78 19 79 20 /* … … 84 25 85 26 /* 86 * [i0 .. i0] [1 1 1]27 * [i0 .. i0] [1 1 1] 87 28 * m[... ...] = [2 2 2] 88 * [i1 .. i1] [3 3 3]29 * [i1 .. i1] [3 3 3] 89 30 */ 90 91 IMAGE_EXPORT(void) set_si8matrix_i (sint8 **m, int i0, int i1, int j0, int j1);92 IMAGE_EXPORT(void) set_ui8matrix_i (uint8 **m, int i0, int i1, int j0, int j1);93 IMAGE_EXPORT(void) set_si16matrix_i (sint16 **m, int i0, int i1, int j0, int j1);94 IMAGE_EXPORT(void) set_ui16matrix_i (uint16 **m, int i0, int i1, int j0, int j1);95 IMAGE_EXPORT(void) set_si32matrix_i (sint32 **m, int i0, int i1, int j0, int j1);96 IMAGE_EXPORT(void) set_ui32matrix_i (uint32 **m, int i0, int i1, int j0, int j1);97 IMAGE_EXPORT(void) set_si64matrix_i (sint64 **m, int i0, int i1, int j0, int j1);98 IMAGE_EXPORT(void) set_ui64matrix_i (uint64 **m, int i0, int i1, int j0, int j1);99 100 IMAGE_EXPORT(void) set_f32matrix_i (float32 **m, int i0, int i1, int j0, int j1);101 IMAGE_EXPORT(void) set_f64matrix_i (float64 **m, int i0, int i1, int j0, int j1);102 103 IMAGE_EXPORT(void) set_rgb8matrix_i (rgb8 **m, int i0, int i1, int j0, int j1);104 IMAGE_EXPORT(void) set_rgbx8matrix_i(rgbx8 **m, int i0, int i1, int j0, int j1);105 31 106 32 /* … … 111 37 112 38 /* 113 * [j0 .. j1][1 2 3]114 * m[... .. ...] = [1 2 3]115 * [j0 .. j1][1 2 3]116 */39 * [j0 .. j1] [1 2 3] 40 * m[... .. ...] = [1 2 3] 41 * [j0 .. j1] [1 2 3] 42 */ 117 43 118 IMAGE_EXPORT(void) set_si8matrix_j (sint8 **m, int i0, int i1, int j0, int j1); 119 IMAGE_EXPORT(void) set_ui8matrix_j (uint8 **m, int i0, int i1, int j0, int j1); 120 IMAGE_EXPORT(void) set_si16matrix_j (sint16 **m, int i0, int i1, int j0, int j1); 121 IMAGE_EXPORT(void) set_ui16matrix_j (uint16 **m, int i0, int i1, int j0, int j1); 122 IMAGE_EXPORT(void) set_si32matrix_j (sint32 **m, int i0, int i1, int j0, int j1); 123 IMAGE_EXPORT(void) set_ui32matrix_j (uint32 **m, int i0, int i1, int j0, int j1); 124 IMAGE_EXPORT(void) set_si64matrix_j (sint64 **m, int i0, int i1, int j0, int j1); 125 IMAGE_EXPORT(void) set_ui64matrix_ (uint64 **m, int i0, int i1, int j0, int j1); 44 #define set_type_matrix(t) \ 45 void short_name(t,zero_,matrix)(t ** m, int32_t i0, int32_t i1, int32_t j0, int32_t j1); \ 46 void short_name(t,set_,matrix)(t ** m, int32_t i0, int32_t i1, int32_t j0, int32_t j1, t x); \ 47 void short_name(t,set_,matrix_param)(t ** m, int32_t i0, int32_t i1, int32_t j0, int32_t j1, t x, t xstep, t ystep); \ 48 void short_name(t,set_,matrix_i)(t ** m, int32_t i0, int32_t i1, int32_t j0, int32_t j1); \ 49 void short_name(t,set_,matrix_j)(t ** m, int32_t i0, int32_t i1, int32_t j0, int32_t j1); 126 50 127 IMAGE_EXPORT(void) set_f32matrix_j (float32 **m, int i0, int i1, int j0, int j1);128 IMAGE_EXPORT(void) set_f64matrix_j (float64 **m, int i0, int i1, int j0, int j1);129 51 130 IMAGE_EXPORT(void) set_rgb8matrix_j (rgb8 **m, int i0, int i1, int j0, int j1); 131 IMAGE_EXPORT(void) set_rgbx8matrix_j(rgbx8 **m, int i0, int i1, int j0, int j1); 52 set_type_matrix(int8_t); 53 set_type_matrix(uint8_t); 54 set_type_matrix(int16_t); 55 set_type_matrix(uint16_t); 56 set_type_matrix(int32_t); 57 set_type_matrix(uint32_t); 58 set_type_matrix(int64_t); 59 set_type_matrix(uint64_t); 60 set_type_matrix(float); 61 set_type_matrix(double); 62 set_type_matrix(rgb8); 63 set_type_matrix(rgbx8); 64 65 132 66 133 67 /* … … 135 69 */ 136 70 71 #define set_type_matrix_border(t) \ 72 void short_name(t,set_,matrix_border)(t ** m, int32_t i0, int32_t i1, int32_t j0, int32_t j1, int32_t n, t x); \ 73 void short_name(t,set_,matrix_border1)(t ** m, int32_t i0, int32_t i1, int32_t j0, int32_t j1, t x); 137 74 138 IMAGE_EXPORT(void) set_ui8matrix_border1(uint8 **m,int i0,int i1,int j0, int j1, uint8 x); 139 IMAGE_EXPORT(void) set_ui8matrix_border (uint8 **m,int i0,int i1,int j0, int j1, int n, uint8 x); 75 set_type_matrix_border(int8_t); 76 set_type_matrix_border(uint8_t); 77 set_type_matrix_border(int16_t); 78 set_type_matrix_border(uint16_t); 79 set_type_matrix_border(int32_t); 80 set_type_matrix_border(uint32_t); 81 set_type_matrix_border(int64_t); 82 set_type_matrix_border(uint64_t); 83 set_type_matrix_border(float); 84 set_type_matrix_border(double); 140 85 141 #ifdef __cplusplus 142 } 143 #endif 86 144 87 145 88 #endif // _NR_SET2_H_ 89 90 // Local Variables: 91 // tab-width: 4 92 // c-basic-offset: 4 93 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 94 // indent-tabs-mode: nil 95 // End: 96 97 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 98 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrset2x.h
r772 r826 4 4 */ 5 5 6 IMAGE_EXPORT(void) zero_si32Pmatrix(si32Point **m, long nrl,long nrh,long ncl,long nch); 7 IMAGE_EXPORT(void) zero_f32Pmatrix ( f32Point **m, long nrl,long nrh,long ncl,long nch); 8 IMAGE_EXPORT(void) zero_si32Tmatrix(si32Triplet **m, long nrl,long nrh,long ncl,long nch); 9 IMAGE_EXPORT(void) zero_f32Tmatrix ( f32Triplet **m, long nrl,long nrh,long ncl,long nch); 6 7 #undef zero_type_matrix 8 #define zero_type_matrix(t) \ 9 void short_name(t,zero_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch); 10 11 zero_type_matrix(si16Point); 12 zero_type_matrix(ui16Point); 13 zero_type_matrix(si32Point); 14 zero_type_matrix(ui32Point); 15 zero_type_matrix(f32Point); 16 zero_type_matrix(si16Triplet); 17 zero_type_matrix(ui16Triplet); 18 zero_type_matrix(si32Triplet); 19 zero_type_matrix(ui32Triplet); 20 zero_type_matrix(f32Triplet); 21 22 23 // Local Variables: 24 // tab-width: 4 25 // c-basic-offset: 4 26 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 27 // indent-tabs-mode: nil 28 // End: 29 30 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 31 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrset3.h
r772 r826 11 11 #define _NR_SET3_H_ 12 12 13 #ifdef __cplusplus14 #pragma message ("C++")15 extern "C" {16 #endif17 18 #ifdef VERBOSE_PRAGMA19 //#pragma message ("- *** include nrset3.h ***")20 #endif21 22 13 // ----------------- 23 14 // --- zero_cube --- 24 15 // ----------------- 25 16 26 IMAGE_EXPORT(void) zero_si8cube (sint8 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 27 IMAGE_EXPORT(void) zero_ui8cube (uint8 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 28 IMAGE_EXPORT(void) zero_si16cube (sint16 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 29 IMAGE_EXPORT(void) zero_ui16cube (uint16 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 30 IMAGE_EXPORT(void) zero_si32cube (sint32 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 31 IMAGE_EXPORT(void) zero_ui32cube (uint32 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 32 IMAGE_EXPORT(void) zero_si64cube (sint64 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 33 IMAGE_EXPORT(void) zero_ui64cube (uint64 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 34 IMAGE_EXPORT(void) zero_f32cube (float32 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 35 IMAGE_EXPORT(void) zero_f64cube (float64 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 36 IMAGE_EXPORT(void) zero_rgb8cube (rgb8 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 37 IMAGE_EXPORT(void) zero_rgbx8cube(rgbx8 ***c, int k0, int k1, int i0, int i1, int j0, int j1); 17 #define zero_type_cube(t) \ 18 void short_name(t,zero_,cube)(t *** c, int32_t k0, int32_t k1, int32_t i0, int32_t i1, int32_t j0, int32_t j1); 19 20 zero_type_cube(int8_t); 21 zero_type_cube(uint8_t); 22 zero_type_cube(int16_t); 23 zero_type_cube(uint16_t); 24 zero_type_cube(int32_t); 25 zero_type_cube(uint32_t); 26 zero_type_cube(int64_t); 27 zero_type_cube(uint64_t); 28 zero_type_cube(float); 29 zero_type_cube(double); 30 zero_type_cube(rgb8); 31 zero_type_cube(rgbx8); 32 38 33 39 34 // ---------------------- … … 41 36 // ---------------------- 42 37 43 IMAGE_EXPORT(void) set_si8cube_param (sint8 ***c, int k0, int k1, int i0, int i1, int j0, int j1, sint8 x, sint8 xstep, sint8 ystep, sint8 zstep); 44 IMAGE_EXPORT(void) set_ui8cube_param (uint8 ***c, int k0, int k1, int i0, int i1, int j0, int j1, uint8 x, uint8 xstep, uint8 ystep, uint8 zstep); 45 IMAGE_EXPORT(void) set_si16cube_param (sint16 ***c, int k0, int k1, int i0, int i1, int j0, int j1, sint16 x, sint16 xstep, sint16 ystep, sint16 zstep); 46 IMAGE_EXPORT(void) set_ui16cube_param (uint16 ***c, int k0, int k1, int i0, int i1, int j0, int j1, uint16 x, uint16 xstep, uint16 ystep, uint16 zstep); 47 IMAGE_EXPORT(void) set_si32cube_param (sint32 ***c, int k0, int k1, int i0, int i1, int j0, int j1, sint32 x, sint32 xstep, sint32 ystep, sint32 zstep); 48 IMAGE_EXPORT(void) set_ui32cube_param (uint32 ***c, int k0, int k1, int i0, int i1, int j0, int j1, uint32 x, uint32 xstep, uint32 ystep, uint32 zstep); 49 IMAGE_EXPORT(void) set_si64cube_param (sint64 ***c, int k0, int k1, int i0, int i1, int j0, int j1, sint64 x, sint64 xstep, sint64 ystep, sint64 zstep); 50 IMAGE_EXPORT(void) set_ui64cube_param (uint64 ***c, int k0, int k1, int i0, int i1, int j0, int j1, uint64 x, uint64 xstep, uint64 ystep, uint64 zstep); 51 IMAGE_EXPORT(void) set_f32cube_param (float32 ***c, int k0, int k1, int i0, int i1, int j0, int j1, float32 x, float32 xstep, float32 ystep, float32 zstep); 52 IMAGE_EXPORT(void) set_f64cube_param (float64 ***c, int k0, int k1, int i0, int i1, int j0, int j1, float64 x, float64 xstep, float64 ystep, float64 zstep); 53 IMAGE_EXPORT(void) set_rgb8cube_param (rgb8 ***c, int k0, int k1, int i0, int i1, int j0, int j1, rgb8 x, rgb8 xstep, rgb8 ystep, rgb8 zstep); 54 IMAGE_EXPORT(void) set_rgbx8cube_param(rgbx8 ***c, int k0, int k1, int i0, int i1, int j0, int j1, rgbx8 x, rgbx8 xstep, rgbx8 ystep, rgbx8 zstep); 38 #define set_type_cube_param(t) \ 39 void short_name(t,set_,cube_param)(t *** c, int32_t k0, int32_t k1, int32_t i0, int32_t i1, int32_t j0, int32_t j1, t x, t xstep, t ystep, t zstep); 55 40 56 #ifdef __cplusplus 57 } 58 #endif 41 set_type_cube_param(int8_t); 42 set_type_cube_param(uint8_t); 43 set_type_cube_param(int16_t); 44 set_type_cube_param(uint16_t); 45 set_type_cube_param(int32_t); 46 set_type_cube_param(uint32_t); 47 set_type_cube_param(int64_t); 48 set_type_cube_param(uint64_t); 49 set_type_cube_param(float); 50 set_type_cube_param(double); 51 set_type_cube_param(rgb8); 52 set_type_cube_param(rgbx8); 53 54 59 55 60 56 #endif // _NR_SET3_H_ 57 58 // Local Variables: 59 // tab-width: 4 60 // c-basic-offset: 4 61 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 62 // indent-tabs-mode: nil 63 // End: 64 65 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 66 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrsort1.h
r772 r826 11 11 #define _NRSORT1_H_ 12 12 13 #ifdef __cplusplus 14 #ifdef PRAGMA_VERBOSE 15 #pragma message ("C++") 16 #endif 17 extern "C" { 18 #endif 13 #define extractnz_boundaries_type_vector(t) \ 14 void short_name(t,extractnz_boundaries_,vector)(t * v, int32_t nl, int32_t nh, int32_t * nlnz, int32_t * nhnz); 19 15 20 #ifdef PRAGMA_VERBOSE 21 //#pragma message("- include nrsort1.h") 22 #endif 16 extractnz_boundaries_type_vector(int8_t); 17 extractnz_boundaries_type_vector(uint8_t); 18 extractnz_boundaries_type_vector(int16_t); 19 extractnz_boundaries_type_vector(uint16_t); 20 extractnz_boundaries_type_vector(int32_t); 21 extractnz_boundaries_type_vector(uint32_t); 22 extractnz_boundaries_type_vector(int64_t); 23 extractnz_boundaries_type_vector(uint64_t); 24 extractnz_boundaries_type_vector(float); 25 extractnz_boundaries_type_vector(double); 23 26 24 IMAGE_EXPORT(void) extractnz_boundaries_ui8vector (uint8 *v, long nl, long nh, long *nlnz, long *nhnz);25 IMAGE_EXPORT(void) extractnz_boundaries_si16vector(sint16 *v, long nl, long nh, long *nlnz, long *nhnz);26 IMAGE_EXPORT(void) extractnz_boundaries_ui16vector(uint16 *v, long nl, long nh, long *nlnz, long *nhnz);27 IMAGE_EXPORT(void) extractnz_boundaries_si32vector(sint32 *v, long nl, long nh, long *nlnz, long *nhnz);28 IMAGE_EXPORT(void) extractnz_boundaries_ui32vector(uint32 *v, long nl, long nh, long *nlnz, long *nhnz);29 IMAGE_EXPORT(void) extractnz_boundaries_f32vector (float32 *v, long nl, long nh, long *nlnz, long *nhnz, float32 epsillon);30 IMAGE_EXPORT(void) extractnz_boundaries_f64vector (float64 *v, long nl, long nh, long *nlnz, long *nhnz, float64 epsillon);31 32 IMAGE_EXPORT(void) sort_index_dvector_selection (double *key, long nl, long nh, int *index);33 27 34 IMAGE_EXPORT(void) sort_index_ivector_selection_min (int *key, long nl, long nh, int *index);35 IMAGE_EXPORT(void) sort_index_ivector_selection_max (int *key, long nl, long nh, int *index);36 IMAGE_EXPORT(void) sort_index_ivector_selection_kmin(int *key, long nl, long nh, int *index, int k);37 IMAGE_EXPORT(void) sort_index_ivector_selection_kmax(int *key, long nl, long nh, int *index, int k);38 28 39 IMAGE_EXPORT(void) sort_index_vector_selection_min (float *key, long nl, long nh, int *index); 40 IMAGE_EXPORT(void) sort_index_vector_selection_max (float *key, long nl, long nh, int *index); 41 IMAGE_EXPORT(void) sort_index_vector_selection_kmin(float *key, long nl, long nh, int *index, int k); 42 IMAGE_EXPORT(void) sort_index_vector_selection_kmax(float *key, long nl, long nh, int *index, int k); 29 void sort_index_f64vector_selection(double * key, int32_t nl, int32_t nh, int32_t * index); 30 void sort_index_ivector_selection_min(int32_t * key, int32_t nl, int32_t nh, int32_t * index); 31 void sort_index_ivector_selection_max(int32_t * key, int32_t nl, int32_t nh, int32_t * index); 32 void sort_index_vector_selection_min(float * key, int32_t nl, int32_t nh, int32_t * index); 33 void sort_index_vector_selection_max(float * key, int32_t nl, int32_t nh, int32_t * index); 34 void sort_index_vector_selection_kmin(float * key, int32_t nl, int32_t nh, int32_t * index, int32_t k); 35 void sort_index_ivector_selection_kmin(int32_t * key, int32_t nl, int32_t nh, int32_t * index, int32_t k); 36 void sort_index_vector_selection_kmax(float * key, int32_t nl, int32_t nh, int32_t * index, int32_t k); 37 void sort_index_ivector_selection_kmax(int32_t * key, int32_t nl, int32_t nh, int32_t * index, int32_t k); 38 void sort_bvector_selection_min(int8_t * v, int32_t nl, int32_t nh); 43 39 44 40 /* … … 46 42 */ 47 43 48 IMAGE_EXPORT(void) sort_bvector_selection_min(byte *v, long nl, long nh);49 44 50 45 /* ======================================================================== */ 51 46 /* == Select = order/rank filter = median ================================= */ 52 47 /* ======================================================================== */ 48 int8_t select_bvector(int8_t * v, int32_t nl, int32_t nh, int32_t k); 49 rgb8 select_rgb8vector(rgb8 * v, int32_t nl, int32_t nh, int32_t k); 53 50 54 IMAGE_EXPORT(byte) select_bvector (byte *v, long nl, long nh, long k);55 IMAGE_EXPORT(rgb8) select_rgb8vector(rgb8 *v, long nl, long nh, long k);56 51 57 #ifdef __cplusplus58 }59 #endif60 52 61 53 #endif /* _NRSORT1_H_ */ 54 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrsort2.h
r772 r826 11 11 #define _NRSORT2_H_ 12 12 13 #ifdef __cplusplus 14 #ifdef PRAGMA_VERBOSE 15 #pragma message ("C++") 16 #endif 17 extern "C" { 18 #endif 13 #define extractnz_boundaries_type_matrix(t) \ 14 void short_name(t,extractnz_boundaries_,matrix)(t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t * nclnz, int32_t * nchnz); 19 15 20 #ifdef PRAGMA_VERBOSE 21 //#pragma message("- include nrsort2.h") 22 #endif 16 extractnz_boundaries_type_matrix(int8_t); 17 extractnz_boundaries_type_matrix(uint8_t); 18 extractnz_boundaries_type_matrix(int16_t); 19 extractnz_boundaries_type_matrix(uint16_t); 20 extractnz_boundaries_type_matrix(int32_t); 21 extractnz_boundaries_type_matrix(uint32_t); 22 extractnz_boundaries_type_matrix(int64_t); 23 extractnz_boundaries_type_matrix(uint64_t); 24 extractnz_boundaries_type_matrix(float); 25 extractnz_boundaries_type_matrix(double); 23 26 24 IMAGE_EXPORT(void) sort_dmatrix_selection (double *m, long nl, long nh);25 27 26 IMAGE_EXPORT(void) sort_imatrix_selection2(int **m, long nl, long nh); 27 IMAGE_EXPORT(void) sort_imatrix_selection (int **m, long nrl, long nrh, long ncl, long nch, long nrow); 28 void sort_si32matrix_selection2(int32_t ** m, int32_t nl, int32_t nh); 29 void sort_f64matrix_selection(double * m, int32_t nl, int32_t nh); 30 void sort_si32matrix_selection(int32_t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t nrow); 31 void sort_si32matrix_leftpart_selection2(int32_t ** m, int32_t nl, int32_t nh, int32_t len); 28 32 29 IMAGE_EXPORT(void) sort_imatrix_leftpart_selection2(int **m, long nl, long nh, long len);30 33 /* 31 34 * Sort the first len item of a 2-row matrix 32 35 */ 33 36 34 IMAGE_EXPORT(void) sort_index_imatrix_selection_kmin(int **key, long nrl,long nrh,long ncl, long nch, int **index, int k); 35 IMAGE_EXPORT(void) sort_index_imatrix_selection_kmax(int **key, long nrl,long nrh,long ncl, long nch, int **index, int k); 37 void sort_index_si32matrix_selection_kmin(int32_t ** key, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t ** index, int32_t k); 38 void sort_index_si32matrix_selection_kmax(int32_t ** key, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t ** index, int32_t k); 39 36 40 /* 37 41 * appel de "sort_index_ivector_selection_k" pour chaque ligne … … 39 43 */ 40 44 41 IMAGE_EXPORT(void) sortv_imatrix_selection_min(int **m, long nrl,long nrh,long ncl, long nch, long nc); 42 IMAGE_EXPORT(void) sortv_imatrix_selection_max(int **m, long nrl,long nrh,long ncl, long nch, long nc); 43 44 IMAGE_EXPORT(void) sortv_imatrix_selection_kmin(int **m, long nrl,long nrh,long ncl, long nch, long nc, int k); 45 IMAGE_EXPORT(void) sortv_imatrix_selection_kmax(int **m, long nrl,long nrh,long ncl, long nch, long nc, int k); 45 void sortv_si32matrix_selection_min(int32_t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t nc); 46 void sortv_si32matrix_selection_max(int32_t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t nc); 47 void sortv_si32matrix_selection_kmin(int32_t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t nc, int32_t k); 48 void sortv_si32matrix_selection_kmax(int32_t ** m, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t nc, int32_t k); 46 49 47 50 /* … … 49 52 * tri vertical, d'une partie des lignes 50 53 */ 51 IMAGE_EXPORT(void) sortv_index_imatrix_selection_max(int **key, long nrl,long nrh,long ncl, long nch, int *index, int nc); 52 IMAGE_EXPORT(void) sortv_index_imatrix_selection_min(int **key, long nrl,long nrh,long ncl, long nch, int *index, int nc); 54 55 void sortv_index_imatrix_selection_max(int ** key, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t * index, int32_t nc); 56 void sortv_index_imatrix_selection_min(int32_t ** key, int32_t nrl, int32_t nrh, int32_t ncl, int32_t nch, int32_t * index, int32_t nc); 57 53 58 /* 54 59 * trie de la colonne nc de la matrice key, nc[ncl..nch] … … 56 61 */ 57 62 58 #ifdef __cplusplus 59 } 60 #endif 63 #endif /* _NRSORT2_H_ */ 61 64 62 #endif /* _NRSORT2_H_ */ 65 // Local Variables: 66 // tab-width: 4 67 // c-basic-offset: 4 68 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 69 // indent-tabs-mode: nil 70 // End: 71 72 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 73 -
soft/giet_vm/applications/rosenfeld/nrc2/include/nrwrap1.h
r772 r826 13 13 #define _NR_WRAP1_H_ 14 14 15 #ifdef __cplusplus16 #pragma message ("C++")17 extern "C" {18 #endif19 20 #ifdef VERBOSE_PRAGMA21 //#pragma message ("- *** include nrwrap1.h ***")22 #endif23 15 24 16 // ------------------------------- // … … 58 50 IMAGE_EXPORT(rgbx8*) rgbx8vector_map_1D_pitch(rgbx8 *v, int nl, int nh, void *data_1D, int pitch); 59 51 60 #ifdef __cplusplus 61 } 62 #endif 52 #endif // _NR_WRAP1_H_ 63 53 64 #endif // _NR_WRAP1_H_ 54 // Local Variables: 55 // tab-width: 4 56 // c-basic-offset: 4 57 // c-file-offsets:((innamespace . 0)(inline-open . 0)) 58 // indent-tabs-mode: nil 59 // End: 60 61 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=4:softtabstop=4 62
Note: See TracChangeset
for help on using the changeset viewer.