void ForceValidityVisitor::visit( MultiPolygon& g ) { g.forceValidityFlag( valid_ ); for ( size_t i = 0; i < g.numGeometries(); i++ ) { visit( g.polygonN( i ) ); } }
std::auto_ptr< MultiLineString > straightSkeleton( const MultiPolygon& g ) { std::auto_ptr< MultiLineString > result( new MultiLineString ); for ( size_t i = 0; i < g.numGeometries(); i++ ){ Polygon_with_holes_2 polygon = g.polygonN(i).toPolygon_with_holes_2() ; boost::shared_ptr< Straight_skeleton_2 > skeleton = CGAL::create_interior_straight_skeleton_2( polygon ) ; straightSkeletonToMultiLineString( *skeleton, *result ) ; } return result ; }
void BoundaryVisitor::visit( const MultiPolygon& g ) { graph::GeometryGraph graph ; graph::GeometryGraphBuilder graphBuilder( graph ) ; for ( size_t i = 0; i < g.numGeometries(); i++ ) { graphBuilder.addPolygon( g.polygonN( i ) ); } getBoundaryFromPolygons( graph ) ; }
std::auto_ptr< Geometry > building( const MultiPolygon& g, const Kernel::FT& wallHeight, const Kernel::FT& roofSlope ) { std::auto_ptr< MultiSolid > multiSolid( new MultiSolid ); for ( size_t i = 0; i < g.numGeometries(); i++ ) { multiSolid->addGeometry( building( g.polygonN( i ), wallHeight, roofSlope ).release() ); } return std::auto_ptr< Geometry >( multiSolid.release() ); }
void GetPointsVisitor::visit( const MultiPolygon& g ) { for ( size_t i = 0; i < g.numGeometries(); i++ ) { visit( g.polygonN( i ) ); } }