Skip to content

Class SFCGAL::graph::GeometryGraphBuilderT

template <typename Graph>

ClassList > SFCGAL > graph > GeometryGraphBuilderT

[private]Convert Geometries to a GeometryGraph. Identifier in the Graph are returned in order to allow the user to keep identify the geometry. More...

  • #include <GeometryGraphBuilder.h>

Public Types

Type Name
typedef std::map< Coordinate, vertex_descriptor > coordinate_list
typedef graph_t::edge_descriptor edge_descriptor
typedef graph_t::edge_properties edge_properties
typedef Graph graph_t
typedef graph_t::vertex_descriptor vertex_descriptor
typedef graph_t::vertex_properties vertex_properties

Public Functions

Type Name
GeometryGraphBuilderT (graph_t & graph)
edge_descriptor addLineSegment (const Point & a, const Point & b, const edge_properties & edgeProperties=edge_properties())
std::vector< edge_descriptor > addLineString (const LineString & lineString, const edge_properties & edgeProperties=edge_properties())
vertex_descriptor addPoint (const Point & point)
std::vector< std::vector< edge_descriptor > > addPolygon (const Polygon & polygon, const edge_properties & edgeProperties=edge_properties())
std::vector< std::vector< std::vector< edge_descriptor > > > addPolyhedralSurface (const PolyhedralSurface & polyhedralSurface, const edge_properties & edgeProperties=edge_properties())
std::vector< edge_descriptor > addTriangle (const Triangle & triangle, const edge_properties & edgeProperties=edge_properties())
std::vector< std::vector< edge_descriptor > > addTriangulatedSurface (const TriangulatedSurface & triangulatedSurface, const edge_properties & edgeProperties=edge_properties())
~GeometryGraphBuilderT ()

Detailed Description

Todo

wrap vertex_descriptor, std::vector< edge_descriptor >, etc. in SharedPoint, SharedLineString, SharedPolygon, etc. and add utility method on the Graph?

Public Types Documentation

typedef coordinate_list

typedef std::map<Coordinate, vertex_descriptor> SFCGAL::graph::GeometryGraphBuilderT< Graph >::coordinate_list;

allows to match duplicates


typedef edge_descriptor

typedef graph_t::edge_descriptor SFCGAL::graph::GeometryGraphBuilderT< Graph >::edge_descriptor;

typedef edge_properties

typedef graph_t::edge_properties SFCGAL::graph::GeometryGraphBuilderT< Graph >::edge_properties;

typedef graph_t

typedef Graph SFCGAL::graph::GeometryGraphBuilderT< Graph >::graph_t;

typedef vertex_descriptor

typedef graph_t::vertex_descriptor SFCGAL::graph::GeometryGraphBuilderT< Graph >::vertex_descriptor;

typedef vertex_properties

typedef graph_t::vertex_properties SFCGAL::graph::GeometryGraphBuilderT< Graph >::vertex_properties;

Public Functions Documentation

function GeometryGraphBuilderT [1/2]

inline SFCGAL::graph::GeometryGraphBuilderT::GeometryGraphBuilderT (
    graph_t & graph
) 

default constructor


function addLineSegment

inline edge_descriptor SFCGAL::graph::GeometryGraphBuilderT::addLineSegment (
    const Point & a,
    const Point & b,
    const edge_properties & edgeProperties=edge_properties()
) 

add a Point to the Graph

Returns:

the edge inserted into the graph


function addLineString

inline std::vector< edge_descriptor > SFCGAL::graph::GeometryGraphBuilderT::addLineString (
    const LineString & lineString,
    const edge_properties & edgeProperties=edge_properties()
) 

add a LineString to the graph

Returns:

the list of edges inserted into the graph


function addPoint

inline vertex_descriptor SFCGAL::graph::GeometryGraphBuilderT::addPoint (
    const Point & point
) 

add a Point to the Graph


function addPolygon

inline std::vector< std::vector< edge_descriptor > > SFCGAL::graph::GeometryGraphBuilderT::addPolygon (
    const Polygon & polygon,
    const edge_properties & edgeProperties=edge_properties()
) 

add a Polygon to the graph

Returns:

the list of rings inserted into the graph


function addPolyhedralSurface

inline std::vector< std::vector< std::vector< edge_descriptor > > > SFCGAL::graph::GeometryGraphBuilderT::addPolyhedralSurface (
    const PolyhedralSurface & polyhedralSurface,
    const edge_properties & edgeProperties=edge_properties()
) 

add a PolyhedralSurface to the graph

Returns:

the list of rings inserted into the graph


function addTriangle

inline std::vector< edge_descriptor > SFCGAL::graph::GeometryGraphBuilderT::addTriangle (
    const Triangle & triangle,
    const edge_properties & edgeProperties=edge_properties()
) 

add a Triangle to the graph

Returns:

the list of edges inserted into the graph


function addTriangulatedSurface

inline std::vector< std::vector< edge_descriptor > > SFCGAL::graph::GeometryGraphBuilderT::addTriangulatedSurface (
    const TriangulatedSurface & triangulatedSurface,
    const edge_properties & edgeProperties=edge_properties()
) 

add a TriangulatedSurface to the graph

Returns:

the list of rings inserted into the graph


function ~GeometryGraphBuilderT

inline SFCGAL::graph::GeometryGraphBuilderT::~GeometryGraphBuilderT () 

destructor



The documentation for this class was generated from the following file /builds/sfcgal/SFCGAL/src/detail/graph/GeometryGraphBuilder.h