...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
Centroid calculation using algorithm Bashein / Detmer.
Calculates centroid using triangulation method published by Bashein / Detmer
template<typename Ignored1, typename Ignored2, typename CalculationType, , > class strategy::centroid::bashein_detmer { // ... };
Parameter |
Default |
Description |
---|---|---|
typename Ignored1 |
void |
|
typename Ignored2 |
void |
|
typename CalculationType |
void |
numeric type for calculation (e.g. high precision); if void then it is extracted automatically from the coordinate type and (if necessary) promoted to floating point |
point type of centroid to calculate |
||
point type of segments, defaults to Point |
Function |
Description |
Parameters |
Returns |
---|---|---|---|
template<typename GeometryPoint, typename ResultPoint> void apply(GeometryPoint const & p1, GeometryPoint const & p2, sums< GeometryPoint, ResultPoint > & state)
|
GeometryPoint const &: p1: GeometryPoint const &: p2: sums< GeometryPoint, ResultPoint > &: state: |
||
template<typename GeometryPoint, typename ResultPoint> bool result(sums< GeometryPoint, ResultPoint > const & state, ResultPoint & centroid)
|
sums< GeometryPoint, ResultPoint > const &: state: ResultPoint &: centroid: |
#include <boost/geometry/strategies/cartesian/centroid_bashein_detmer.hpp>