DGtal 2.1.0
|
Public Types | |
typedef Value | ValueType |
Public Member Functions | |
DynArrayLXY (unsigned int _L, unsigned int _X, unsigned int _Y, Value invalid) | |
~DynArrayLXY () | |
void | clear () |
size_t | offset (unsigned int l, unsigned int x, unsigned int y) const |
const Value & | value (unsigned int l, unsigned int x, unsigned int y) const |
unsigned int | erase (unsigned int l, unsigned int x, unsigned int y) |
void | setValue (const Value &val, unsigned int l, unsigned int x, unsigned int y) |
void | setValueNoNewLabel (const Value &val, unsigned int l, unsigned int x, unsigned int y) |
bool | hasLabel (unsigned int l, unsigned int x, unsigned int y) const |
void | getLabels (std::vector< unsigned int > &labels, unsigned int x, unsigned int y) const |
unsigned int | nbLabels (unsigned int x, unsigned int y) const |
void | display (ostream &, unsigned int, unsigned int, unsigned int) |
unsigned long long | area () const |
Data Fields | |
const unsigned int | L |
const unsigned int | X |
const unsigned int | Y |
Private Attributes | |
Value * | _data |
Value | _invalid |
Array[L][X][Y] of value. Brute-force. High memory consumption. Rather fast except when working with several labels.
Note that 4000*4000*16 is upper limit on my 8Gb laptop (2Gb). Note that 2000*2000*64 is upper limit on my 8Gb laptop (2Gb).
Definition at line 76 of file testMultiMap-benchmark.cpp.
typedef Value DynArrayLXY< Value >::ValueType |
Definition at line 78 of file testMultiMap-benchmark.cpp.
|
inline |
Definition at line 89 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_data, DynArrayLXY< Value >::_invalid, DynArrayLXY< Value >::clear(), DynArrayLXY< Value >::L, DynArrayLXY< Value >::X, and DynArrayLXY< Value >::Y.
|
inline |
Definition at line 97 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_data.
|
inline |
Definition at line 169 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::L, DynArrayLXY< Value >::X, and DynArrayLXY< Value >::Y.
|
inline |
Definition at line 102 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_invalid, DynArrayLXY< Value >::L, DynArrayLXY< Value >::setValue(), DynArrayLXY< Value >::X, and DynArrayLXY< Value >::Y.
Referenced by DynArrayLXY< Value >::DynArrayLXY().
|
inline |
Definition at line 165 of file testMultiMap-benchmark.cpp.
|
inline |
Definition at line 121 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_data, DynArrayLXY< Value >::_invalid, and DynArrayLXY< Value >::offset().
|
inline |
Definition at line 148 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::hasLabel(), and DynArrayLXY< Value >::L.
|
inline |
Definition at line 143 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_invalid, and DynArrayLXY< Value >::value().
Referenced by DynArrayLXY< Value >::getLabels(), and DynArrayLXY< Value >::nbLabels().
|
inline |
Definition at line 157 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::hasLabel(), and DynArrayLXY< Value >::L.
|
inline |
Definition at line 111 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::X, and DynArrayLXY< Value >::Y.
Referenced by DynArrayLXY< Value >::erase(), DynArrayLXY< Value >::setValue(), DynArrayLXY< Value >::setValueNoNewLabel(), and DynArrayLXY< Value >::value().
|
inline |
Definition at line 133 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_data, and DynArrayLXY< Value >::offset().
Referenced by DynArrayLXY< Value >::clear().
|
inline |
Definition at line 138 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_data, and DynArrayLXY< Value >::offset().
|
inline |
Definition at line 116 of file testMultiMap-benchmark.cpp.
References DynArrayLXY< Value >::_data, and DynArrayLXY< Value >::offset().
Referenced by DynArrayLXY< Value >::hasLabel().
|
private |
Definition at line 84 of file testMultiMap-benchmark.cpp.
Referenced by DynArrayLXY< Value >::DynArrayLXY(), DynArrayLXY< Value >::erase(), DynArrayLXY< Value >::setValue(), DynArrayLXY< Value >::setValueNoNewLabel(), DynArrayLXY< Value >::value(), and DynArrayLXY< Value >::~DynArrayLXY().
|
private |
Definition at line 85 of file testMultiMap-benchmark.cpp.
Referenced by DynArrayLXY< Value >::clear(), DynArrayLXY< Value >::DynArrayLXY(), DynArrayLXY< Value >::erase(), and DynArrayLXY< Value >::hasLabel().
const unsigned int DynArrayLXY< Value >::L |
Definition at line 79 of file testMultiMap-benchmark.cpp.
Referenced by DynArrayLXY< Value >::area(), DynArrayLXY< Value >::clear(), DynArrayLXY< Value >::DynArrayLXY(), DynArrayLXY< Value >::getLabels(), and DynArrayLXY< Value >::nbLabels().
const unsigned int DynArrayLXY< Value >::X |
Definition at line 80 of file testMultiMap-benchmark.cpp.
Referenced by DynArrayLXY< Value >::area(), DynArrayLXY< Value >::clear(), DynArrayLXY< Value >::DynArrayLXY(), and DynArrayLXY< Value >::offset().
const unsigned int DynArrayLXY< Value >::Y |
Definition at line 81 of file testMultiMap-benchmark.cpp.
Referenced by DynArrayLXY< Value >::area(), DynArrayLXY< Value >::clear(), DynArrayLXY< Value >::DynArrayLXY(), and DynArrayLXY< Value >::offset().