30 #include "../WBoundingBox.h"
32 #include "../WMixinVector.h"
33 #include "linearAlgebra/WPosition.h"
49 explicit WLine(
const std::vector< WPosition > &points );
122 double pathLength(
const WLine& line );
146 int equalsDelta(
const WLine& line,
const WLine& other,
double delta );
156 double maxSegmentLength(
const WLine& line );
166 bool hasMorePointsThen(
const WLine& first,
const WLine& second );
168 inline bool hasMorePointsThen(
const WLine& first,
const WLine& second )
170 return first.
size() > second.
size();
Unit tests the WLine class.
A line is an ordered sequence of WPositions.
void resampleByNumberOfPoints(size_t numPoints)
Resample this line so it has a number of given points afterwards.
void unifyDirectionBy(const WLine &other)
Put the line into reverse ordering if the reverse ordering would have a similar direction to the give...
void resampleBySegmentLengthKeepShortFibers(double newSegmentLength)
Resample this line so there are only segements of the given length.
void reverseOrder()
Reverses the order of the points.
void removeAdjacentDuplicates()
Collapse samplepoints which are equal and neighboured.
void resampleBySegmentLength(double newSegementLength)
Resample this line so there are only segements of the given length.
WLine()
Creates an empty line.
This is taken from OpenSceneGraph <osg/MixinVector> but copy and pasted in order to reduce dependency...
size_type size() const
Wrapper around std::vector member function.
This only is a 3d double vector.