DGtal
0.6.devel
|
#include <L1LengthEstimator.h>
Public Types | |
typedef TConstIterator | ConstIterator |
typedef double | Quantity |
Public Member Functions | |
L1LengthEstimator () | |
~L1LengthEstimator () | |
void | init (const double h, const ConstIterator &itb, const ConstIterator &ite) |
Quantity | eval () const |
void | selfDisplay (std::ostream &out) const |
bool | isValid () const |
Private Member Functions | |
L1LengthEstimator (const L1LengthEstimator &other) | |
L1LengthEstimator & | operator= (const L1LengthEstimator &other) |
Private Attributes | |
double | myH |
ConstIterator | myBeginIt |
ConstIterator | myEndIt |
bool | myIsInitBefore |
Aim: a simple model of CGlobalCurveEstimator that compute the length of a curve using the l_1 metric (just add 1/h for every step).
Description of template class 'L1LengthEstimator'
Model of CGlobalCurveGeometricEstimator.
TConstIterator | a model of CConstIteratorOnArrows. |
Definition at line 67 of file L1LengthEstimator.h.
typedef TConstIterator DGtal::L1LengthEstimator< TConstIterator >::ConstIterator |
Definition at line 74 of file L1LengthEstimator.h.
typedef double DGtal::L1LengthEstimator< TConstIterator >::Quantity |
Definition at line 76 of file L1LengthEstimator.h.
|
inline |
|
inline |
|
private |
Copy constructor.
other | the object to clone. Forbidden by default. |
|
inline |
Computation of the l1 length of the curve. Complexity: O(|Range|)
Definition at line 83 of file L1LengthEstimator.ih.
References DGtal::isNotEmpty().
|
inline |
Initialize the measure computation.
h | grid size (must be >0). |
itb | begin iterator |
ite | end iterator |
closed | true if the input range is closed. |
Definition at line 70 of file L1LengthEstimator.ih.
|
inline |
Checks the validity/consistency of the object.
Definition at line 132 of file L1LengthEstimator.ih.
|
private |
Assignment.
other | the object to copy. |
|
inline |
Writes/Displays the object on an output stream.
out | the output stream where the object is written. |
Definition at line 116 of file L1LengthEstimator.ih.
|
private |
Copy of the range.
Definition at line 134 of file L1LengthEstimator.h.
|
private |
Definition at line 135 of file L1LengthEstimator.h.
|
private |
Grid size.
Definition at line 131 of file L1LengthEstimator.h.
|
private |
Boolean to make sure that init() has been called before eval().
Definition at line 138 of file L1LengthEstimator.h.