00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029 #ifndef NV_NPPIDEFS_H
00030 #define NV_NPPIDEFS_H
00031
00032 #include <stdlib.h>
00033
00040 #ifdef __cplusplus
00041 extern "C" {
00042 #endif
00043
00051 typedef enum
00052 {
00053 NPPI_INTER_NN = 1,
00054 NPPI_INTER_LINEAR = 2,
00055 NPPI_INTER_CUBIC = 4,
00056 NPPI_INTER_SUPER = 8,
00057 NPPI_INTER_LANCZOS = 16,
00058 NPPI_SMOOTH_EDGE = (1 << 31)
00059 } NppiInterpolationMode;
00060
00069 typedef enum
00070 {
00071
00072 NPP_NOT_SUPPORTED_MODE_ERROR = -9999,
00073 NPP_ROUND_MODE_NOT_SUPPORTED_ERROR = -213,
00074 NPP_RESIZE_NO_OPERATION_ERROR = -50,
00075 NPP_NOT_SUFFICIENT_COMPUTE_CAPABILITY = -27,
00076 NPP_BAD_ARG_ERROR = -26,
00077 NPP_LUT_NUMBER_OF_LEVELS_ERROR = -25,
00078 NPP_TEXTURE_BIND_ERROR = -24,
00079 NPP_COEFF_ERROR = -23,
00080 NPP_RECT_ERROR = -22,
00081 NPP_QUAD_ERROR = -21,
00082 NPP_WRONG_INTERSECTION_ROI_ERROR = -20,
00083 NPP_NOT_EVEN_STEP_ERROR = -19,
00084 NPP_INTERPOLATION_ERROR = -18,
00085 NPP_RESIZE_FACTOR_ERROR = -17,
00086 NPP_HAAR_CLASSIFIER_PIXEL_MATCH_ERROR = -16,
00087 NPP_MEMFREE_ERR = -15,
00088 NPP_MEMSET_ERR = -14,
00089 NPP_MEMCPY_ERROR = -13,
00090 NPP_MEM_ALLOC_ERR = -12,
00091 NPP_HISTO_NUMBER_OF_LEVELS_ERROR = -11,
00092 NPP_MIRROR_FLIP_ERR = -10,
00093 NPP_INVALID_INPUT = -9,
00094 NPP_ALIGNMENT_ERROR = -8,
00095 NPP_STEP_ERROR = -7,
00096 NPP_SIZE_ERROR = -6,
00097 NPP_POINTER_ERROR = -5,
00098 NPP_NULL_POINTER_ERROR = -4,
00099 NPP_CUDA_KERNEL_EXECUTION_ERROR = -3,
00100 NPP_NOT_IMPLEMENTED_ERROR = -2,
00101 NPP_ERROR = -1,
00102
00103
00104 NPP_NO_ERROR = 0,
00105 NPP_SUCCESS = NPP_NO_ERROR,
00106
00107
00108 NPP_WARNING = 1,
00109 NPP_WRONG_INTERSECTION_QUAD_WARNING = 2,
00110 NPP_MISALIGNED_DST_ROI_WARNING = 3,
00111 NPP_AFFINE_QUAD_INCORRECT_WARNING = 4,
00112 NPP_DOUBLE_SIZE_WARNING = 5,
00113 NPP_ODD_ROI_WARNING = 6,
00114 } NppStatus;
00115
00116 typedef enum
00117 {
00118 NPP_CUDA_UNKNOWN_VERSION = -1,
00119 NPP_CUDA_NOT_CAPABLE,
00120 NPP_CUDA_1_0,
00121 NPP_CUDA_1_1,
00122 NPP_CUDA_1_2,
00123 NPP_CUDA_1_3,
00124 NPP_CUDA_2_0
00125 } NppGpuComputeCapability;
00126
00127 typedef struct
00128 {
00129 int major;
00130 int minor;
00131 int build;
00132 } NppLibraryVersion;
00133
00139 typedef unsigned char Npp8u;
00140 typedef signed char Npp8s;
00141 typedef unsigned short Npp16u;
00142 typedef short Npp16s;
00143 typedef unsigned int Npp32u;
00144 typedef int Npp32s;
00145 typedef unsigned long long Npp64u;
00146 typedef long long Npp64s;
00147 typedef float Npp32f;
00148 typedef double Npp64f;
00149
00154 typedef struct
00155 {
00156 Npp16s re;
00157 Npp16s im;
00158 } Npp16sc;
00159
00164 typedef struct
00165 {
00166 Npp32s re;
00167 Npp32s im;
00168 } Npp32sc;
00169
00174 typedef struct
00175 {
00176 Npp32f re;
00177 Npp32f im;
00178 } Npp32fc;
00179
00184 typedef struct
00185 {
00186 Npp64s re;
00187 Npp64s im;
00188 } Npp64sc;
00189
00194 typedef struct
00195 {
00196 Npp64f re;
00197 Npp64f im;
00198 } Npp64fc;
00199
00202 #define NPP_MIN_8U ( 0 )
00203 #define NPP_MAX_8U ( 255 )
00204 #define NPP_MIN_16U ( 0 )
00205 #define NPP_MAX_16U ( 65535 )
00206 #define NPP_MIN_32U ( 0 )
00207 #define NPP_MAX_32U ( 4294967295 )
00208
00209 #define NPP_MIN_8S (-128 )
00210 #define NPP_MAX_8S ( 127 )
00211 #define NPP_MIN_16S (-32768 )
00212 #define NPP_MAX_16S ( 32767 )
00213 #define NPP_MIN_32S (-2147483648 )
00214 #define NPP_MAX_32S ( 2147483647 )
00215 #define NPP_MAX_64S ( 9223372036854775807LL )
00216 #define NPP_MIN_64S (-9223372036854775808LL)
00217
00218 #define NPP_MINABS_32F ( 1.175494351e-38f )
00219 #define NPP_MAXABS_32F ( 3.402823466e+38f )
00220 #define NPP_MINABS_64F ( 2.2250738585072014e-308 )
00221 #define NPP_MAXABS_64F ( 1.7976931348623158e+308 )
00222
00223
00227 typedef struct
00228 {
00229 int x;
00230 int y;
00231 } NppiPoint;
00232
00238 typedef struct
00239 {
00240 int width;
00241 int height;
00242 } NppiSize;
00243
00251 typedef struct
00252 {
00253 int x;
00254 int y;
00255 int width;
00256 int height;
00257 } NppiRect;
00258
00259 typedef enum
00260 {
00261 NPP_HORIZONTAL_AXIS,
00262 NPP_VERTICAL_AXIS,
00263 NPP_BOTH_AXIS
00264 } NppiAxis;
00265
00266 typedef enum
00267 {
00268 NPP_CMP_LESS,
00269 NPP_CMP_LESS_EQ,
00270 NPP_CMP_EQ,
00271 NPP_CMP_GREATER_EQ,
00272 NPP_CMP_GREATER
00273 } NppCmpOp;
00274
00275 typedef enum
00276 {
00277 NPP_RND_ZERO,
00278 NPP_RND_NEAR,
00279 NPP_RND_FINANCIAL
00280 } NppRoundMode;
00281
00282
00283 typedef struct
00284 {
00285 int numClassifiers;
00286 Npp32s * classifiers;
00287 size_t classifierStep;
00288 NppiSize classifierSize;
00289 Npp32s * counterDevice;
00290 } NppiHaarClassifier_32f;
00291
00292 typedef struct
00293 {
00294 int haarBufferSize;
00295 Npp32s * haarBuffer;
00296
00297 } NppiHaarBuffer;
00298
00299 typedef enum {
00300 nppAlgHintNone,
00301 nppAlgHintFast,
00302 nppAlgHintAccurate
00303 } NppHintAlgorithm;
00304
00305 #ifdef __cplusplus
00306 }
00307 #endif
00308
00311 #endif // NV_NPPIDEFS_H