Joe Verbout / Mbed 2 deprecated main

Dependencies:   mbed

Committer:
joeverbout
Date:
Thu Mar 31 21:16:38 2016 +0000
Revision:
0:ea44dc9ed014
OpenCV on mbed attempt

Who changed what in which revision?

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