[/============================================================================ Boost.Geometry (aka GGL, Generic Geometry Library) Copyright (c) 2007-2013 Barend Gehrels, Amsterdam, the Netherlands. Copyright (c) 2008-2013 Bruno Lalande, Paris, France. Copyright (c) 2009-2013 Mateusz Loskot, London, UK. Use, modification and distribution is subject to the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) =============================================================================/] [/ Generated by doxygen_xml2qbk 1.1.1, don't change, will be overwritten automatically] [/ Generated from doxy/doxygen_output/xml/group__centroid.xml] [section:centroid_3_with_strategy centroid (with strategy)] '''centroid''' Calculates the centroid of a geometry using the specified strategy. [heading Description] The free function centroid calculates the geometric center (or: center of mass) of a geometry. Reasons to specify a strategy include: use another coordinate system for calculations; construct the strategy beforehand (e.g. with the radius of the Earth); select a strategy when there are more than one available for a calculation. [heading Synopsis] ``template void centroid(Geometry const & geometry, Point & c, Strategy const & strategy)`` [heading Parameters] [table [[Type] [Concept] [Name] [Description] ] [[Geometry const &] [Any type fulfilling a Geometry Concept ] [geometry] [A model of the specified concept ]] [[Point &] [Any type fulfilling a Point Concept ] [c] [A model of the specified Point Concept which is set to the centroid ]] [[Strategy const &] [Any type fulfilling a Centroid Strategy Concept ] [strategy] [The strategy which will be used for centroid calculations]] ] [heading Header] Either `#include ` Or `#include ` [include reference/algorithms/centroid.qbk] [include reference/algorithms/centroid_strategies.qbk] [endsect] [section:centroid_2 centroid] '''centroid''' Calculates the centroid of a geometry. [heading Description] The free function centroid calculates the geometric center (or: center of mass) of a geometry. It uses the default strategy, based on the coordinate system of the geometry. [heading Synopsis] ``template void centroid(Geometry const & geometry, Point & c)`` [heading Parameters] [table [[Type] [Concept] [Name] [Description] ] [[Geometry const &] [Any type fulfilling a Geometry Concept ] [geometry] [A model of the specified concept ]] [[Point &] [Any type fulfilling a Point Concept ] [c] [The calculated centroid will be assigned to this point reference]] ] [heading Header] Either `#include ` Or `#include ` [include reference/algorithms/centroid.qbk] [heading Example] [centroid] [centroid_output] [endsect] [section:return_centroid_1 return_centroid] '''return_centroid''' Calculates the centroid of a geometry. [heading Description] The free function centroid calculates the geometric center (or: center of mass) of a geometry. This version with the return\u005f prefix returns the centroid, and a template parameter must therefore be specified in the call.. [heading Synopsis] ``template Point return_centroid(Geometry const & geometry)`` [heading Parameters] [table [[Type] [Concept] [Name] [Description] ] [[Point] [Any type fulfilling a Point Concept ] [ - ] [Must be specified]] [[Geometry const &] [Any type fulfilling a Geometry Concept ] [geometry] [A model of the specified concept ]] ] [heading Returns] The calculated centroid [heading Header] Either `#include ` Or `#include ` [include reference/algorithms/centroid.qbk] [endsect] [section:return_centroid_2_with_strategy return_centroid (with strategy)] '''return_centroid''' Calculates the centroid of a geometry using the specified strategy. [heading Description] The free function centroid calculates the geometric center (or: center of mass) of a geometry. This version with the return\u005f prefix returns the centroid, and a template parameter must therefore be specified in the call.. Reasons to specify a strategy include: use another coordinate system for calculations; construct the strategy beforehand (e.g. with the radius of the Earth); select a strategy when there are more than one available for a calculation. [heading Synopsis] ``template Point return_centroid(Geometry const & geometry, Strategy const & strategy)`` [heading Parameters] [table [[Type] [Concept] [Name] [Description] ] [[Point] [Any type fulfilling a Point Concept ] [ - ] [Must be specified]] [[Geometry const &] [Any type fulfilling a Geometry Concept ] [geometry] [A model of the specified concept ]] [[Strategy const &] [Any type fulfilling a centroid Strategy Concept ] [strategy] [The strategy which will be used for centroid calculations ]] ] [heading Returns] The calculated centroid [heading Header] Either `#include ` Or `#include ` [include reference/algorithms/centroid.qbk] [include reference/algorithms/centroid_strategies.qbk] [endsect]