| Home | Libraries | People | FAQ | More

#### strategy::centroid::bashein_detmer

Centroid calculation using algorithm Bashein / Detmer.

###### Description

Calculates centroid using triangulation method published by Bashein / Detmer

###### Synopsis

    template<typename Ignored1, typename Ignored2, typename CalculationType, ,
             >
    class strategy::centroid::bashein_detmer
    {
      // ...
    };

###### Template parameter(s)

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

###### Member Function(s)

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: |

###### Header

`#include <boost/geometry/strategies/cartesian/centroid_bashein_detmer.hpp>`

###### See also

centroid (with strategy)