1[/============================================================================ 2 Boost.Geometry (aka GGL, Generic Geometry Library) 3 4 Copyright (c) 2009-2012 Barend Gehrels, Amsterdam, the Netherlands. 5 Copyright (c) 2009-2012 Mateusz Loskot, London, UK. 6 Copyright (c) 2009-2012 Bruno Lalande, Paris, France. 7 8 Use, modification and distribution is subject to the Boost Software License, 9 Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at 10 http://www.boost.org/LICENSE_1_0.txt) 11=============================================================================/] 12 13[def __this_function__ centroid] 14 15[heading_conformance_ogc __this_function__..Centroid] 16 17[heading Behavior] 18[table 19[[Case] [Behavior] ] 20[[__point__][Returns the point itself as the centroid]] 21[[__multi_point__][Calculates centroid (based on average)]] 22[[__1dim__][Calculates centroid (based on weighted length)]] 23[[__2dim__][Calculates centroid]] 24[[__empty__][Throws a [link geometry.reference.exceptions.centroid_exception centroid_exception] ]] 25[[__cart__][Implemented]] 26[[__sph__][Calculates the centroid as if based on Cartesian coordinates]] 27] 28 29[/ TODO: change by status /] 30[heading Supported geometries] 31[table 32[[ ][2D][3D]] 33[[Point][[$img/ok.png]][[$img/ok.png]]] 34[[Segment][[$img/ok.png]][[$img/ok.png]]] 35[[Box][[$img/ok.png]][[$img/ok.png]]] 36[[Linestring][[$img/ok.png]][[$img/nyi.png]]] 37[[Ring][[$img/ok.png]][[$img/nyi.png]]] 38[[Polygon][[$img/ok.png]][[$img/nyi.png]]] 39[[MultiPoint][[$img/ok.png]][[$img/ok.png]]] 40[[MultiLinestring][[$img/ok.png]][[$img/nyi.png]]] 41[[MultiPolygon][[$img/ok.png]][[$img/nyi.png]]] 42] 43 44[heading Complexity] 45Linear 46 47