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"
46 using namespace DGtal;
55 typedef vector < Point >
Range;
65 inputStream.open ( (testPath +
"samples/sinus2D4.dat").c_str(), ios::in );
73 bool lambda64ByPoint ()
77 lmst64.
attach ( segmenter );
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: Simplify creation of Lambda MST tangent estimator.
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.
Aim: Implements method to read a set of points represented in each line of a file.
ArithmeticalDSSComputer< std::vector< Z2i::Point >::const_iterator, int, 4 > SegmentComputer
SaturatedSegmentation< SegmentComputer > Segmentation