35#include "DGtal/base/Common.h"
36#include "ConfigTest.h"
37#include "DGtal/helpers/StdDefs.h"
38#include "DGtal/io/readers/PointListReader.h"
39#include "DGtal/geometry/curves/ArithmeticalDSSComputer.h"
40#include "DGtal/geometry/curves/estimation/LambdaMST2D.h"
41#include "DGtal/geometry/curves/SaturatedSegmentation.h"
55 typedef vector < Point >
Range;
57 typedef ArithmeticalDSSComputer < ConstIterator, int, 8 >
SegmentComputer;
65 inputStream.open ( (testPath +
"samples/sinus2D4.dat").c_str(), ios::in );
73 bool lambda64ByPoint ()
76 LambdaMST2D < Segmentation > lmst64;
77 lmst64.
attach ( segmenter );
85 LambdaMST2D < Segmentation > lmst64;
86 lmst64.
attach ( segmenter );
88 std::vector < RealVector > tangent;
89 lmst64.
eval < back_insert_iterator< vector < RealVector > > > ( curve.
begin(), curve.
end(), back_inserter ( tangent ) );
101 testLambdaMST2D testLMST;
104 res &= testLMST.lambda64ByPoint();
107 res &= testLMST.lambda64();
109 trace.
emphase() << ( res ?
"Passed." :
"Error." ) << endl;
Aim: This class is a wrapper around ArithmeticalDSS that is devoted to the dynamic recognition of dig...
RealVector eval(const Point &p)
void init(ConstIterator itb, ConstIterator ite)
void attach(Alias< TSegmentation > SegmentComputer)
Aim: Computes the saturated segmentation, that is the whole set of maximal segments within a range gi...
Aim: model of CBidirectionalRangeFromPoint that adapts any range of elements bounded by two iterators...
void beginBlock(const std::string &keyword="")
MyDigitalSurface::ConstIterator ConstIterator
DGtal is the top-level namespace which contains all DGtal functions and types.
static std::vector< TPoint > getPointsFromInputStream(std::istream &in, std::vector< unsigned int > aVectPosition=std::vector< unsigned int >())