| Home | Libraries | People | FAQ | More

#### strategy::centroid::average

Centroid calculation taking average of points.

###### Synopsis

    template<typename PointCentroid, typename Point>
    class strategy::centroid::average
    {
      // ...
    };

###### Template parameter(s)

Parameter | Default | Description
--- | --- | ---
typename PointCentroid |  |
typename Point | PointCentroid |

###### Member Function(s)

Function | Description | Parameters | Returns
--- | --- | --- | ---

    void apply(Point const & p, sum & state)

Point const &: p:

sum &: state:

    void result(sum const & state, PointCentroid & centroid)

sum const &: state:

PointCentroid &: centroid:

###### Header

Either

`#include <boost/geometry/multi/multi.hpp>`

Or

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