defines.h
Go to the documentation of this file.
1 /***********************************************************************
2  * Software License Agreement (BSD License)
3  *
4  * Copyright 2008-2011 Marius Muja (mariusm@cs.ubc.ca). All rights reserved.
5  * Copyright 2008-2011 David G. Lowe (lowe@cs.ubc.ca). All rights reserved.
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions
9  * are met:
10  *
11  * 1. Redistributions of source code must retain the above copyright
12  * notice, this list of conditions and the following disclaimer.
13  * 2. Redistributions in binary form must reproduce the above copyright
14  * notice, this list of conditions and the following disclaimer in the
15  * documentation and/or other materials provided with the distribution.
16  *
17  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
18  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
19  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
20  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27  *************************************************************************/
28 
29 
30 #ifndef OPENCV_FLANN_DEFINES_H_
31 #define OPENCV_FLANN_DEFINES_H_
32 
33 #include "config.h"
34 
35 #ifdef FLANN_EXPORT
36 #undef FLANN_EXPORT
37 #endif
38 #ifdef WIN32
39 /* win32 dll export/import directives */
40  #ifdef FLANN_EXPORTS
41  #define FLANN_EXPORT __declspec(dllexport)
42  #elif defined(FLANN_STATIC)
43  #define FLANN_EXPORT
44  #else
45  #define FLANN_EXPORT __declspec(dllimport)
46  #endif
47 #else
48 /* unix needs nothing */
49  #define FLANN_EXPORT
50 #endif
51 
52 
53 #ifdef FLANN_DEPRECATED
54 #undef FLANN_DEPRECATED
55 #endif
56 #ifdef __GNUC__
57 #define FLANN_DEPRECATED __attribute__ ((deprecated))
58 #elif defined(_MSC_VER)
59 #define FLANN_DEPRECATED __declspec(deprecated)
60 #else
61 #pragma message("WARNING: You need to implement FLANN_DEPRECATED for this compiler")
62 #define FLANN_DEPRECATED
63 #endif
64 
65 
66 #undef FLANN_PLATFORM_32_BIT
67 #undef FLANN_PLATFORM_64_BIT
68 #if defined __amd64__ || defined __x86_64__ || defined _WIN64 || defined _M_X64
69 #define FLANN_PLATFORM_64_BIT
70 #else
71 #define FLANN_PLATFORM_32_BIT
72 #endif
73 
74 
75 #undef FLANN_ARRAY_LEN
76 #define FLANN_ARRAY_LEN(a) (sizeof(a)/sizeof(a[0]))
77 
78 namespace cvflann {
79 
80 /* Nearest neighbour index algorithms */
82 {
92 
93  // deprecated constants, should use the FLANN_INDEX_* ones instead
94  LINEAR = 0,
95  KDTREE = 1,
96  KMEANS = 2,
97  COMPOSITE = 3,
99  SAVED = 254,
100  AUTOTUNED = 255
101 };
102 
103 
104 
106 {
110 
111  // deprecated constants, should use the FLANN_CENTERS_* ones instead
115 };
116 
118 {
124 };
125 
127 {
141 
142  // deprecated constants, should use the FLANN_DIST_* ones instead
146  MAX_DIST = 4,
149  CS = 7,
150  KL = 8,
152 };
153 
155 {
166 };
167 
168 enum
169 {
172 };
173 
174 }
175 
176 #endif /* OPENCV_FLANN_DEFINES_H_ */
Definition: defines.h:131
Definition: defines.h:86
Definition: defines.h:87
flann_algorithm_t
Definition: defines.h:81
Definition: defines.h:171
Definition: defines.h:145
Definition: defines.h:100
Definition: defines.h:161
Definition: defines.h:135
Definition: defines.h:149
Definition: defines.h:108
Definition: defines.h:148
Definition: defines.h:128
Definition: defines.h:137
Definition: defines.h:129
Definition: defines.h:99
Definition: defines.h:94
Definition: defines.h:121
Definition: defines.h:120
Definition: defines.h:157
Definition: defines.h:136
Definition: defines.h:150
Definition: defines.h:85
Definition: defines.h:130
Definition: defines.h:122
Definition: defines.h:98
Definition: defines.h:123
Definition: defines.h:138
flann_datatype_t
Definition: defines.h:154
Definition: defines.h:91
Definition: defines.h:95
Definition: defines.h:151
Definition: defines.h:114
Definition: defines.h:140
Definition: defines.h:134
Definition: defines.h:165
Definition: defines.h:159
Definition: defines.h:96
Definition: defines.h:133
Definition: defines.h:97
flann_centers_init_t
Definition: defines.h:105
flann_log_level_t
Definition: defines.h:117
Definition: defines.h:143
Definition: defines.h:164
Definition: defines.h:132
Definition: defines.h:139
Definition: defines.h:163
Definition: defines.h:146
Definition: defines.h:84
Definition: defines.h:144
Definition: defines.h:170
Definition: defines.h:88
Definition: defines.h:89
Definition: defines.h:119
Definition: defines.h:156
Definition: defines.h:160
Definition: defines.h:147
Definition: defines.h:158
Definition: defines.h:162
Definition: defines.h:107
Definition: defines.h:90
Definition: defines.h:109
Definition: defines.h:112
Definition: defines.h:113
flann_distance_t
Definition: defines.h:126
Definition: defines.h:83