SAGA API  v9.5
shapes_polygons.cpp File Reference
#include "shapes.h"
#include "clipper1/clipper.hpp"

Go to the source code of this file.

Functions

bool _SG_Polygon_Clip (ClipperLib::ClipType ClipType, CSG_Shape *pPolygon, CSG_Shape *pClip, CSG_Shape *pResult)
 
bool SG_Shape_Get_Intersection (CSG_Shape *pPolygon, CSG_Shape_Polygon *pClip, CSG_Shape *pResult)
 
bool SG_Shape_Get_Difference (CSG_Shape *pPolygon, CSG_Shape_Polygon *pClip, CSG_Shape *pResult)
 
bool SG_Shape_Get_ExclusiveOr (CSG_Shape *pPolygon, CSG_Shape_Polygon *pClip, CSG_Shape *pResult)
 
bool SG_Shape_Get_Union (CSG_Shape *pPolygon, CSG_Shape_Polygon *pClip, CSG_Shape *pResult)
 
bool SG_Shape_Get_Dissolve (CSG_Shape *pPolygon, CSG_Shape *pResult)
 
bool SG_Shape_Get_Offset (CSG_Shape *pPolygon, double dSize, double dArc, CSG_Shape *pResult)
 
const char * SG_Clipper_Get_Version (void)
 

Function Documentation

◆ _SG_Polygon_Clip()

bool _SG_Polygon_Clip ( ClipperLib::ClipType  ClipType,
CSG_Shape pPolygon,
CSG_Shape pClip,
CSG_Shape pResult 
)

◆ SG_Clipper_Get_Version()

const char* SG_Clipper_Get_Version ( void  )

Definition at line 470 of file shapes_polygons.cpp.

◆ SG_Shape_Get_Difference()

◆ SG_Shape_Get_Dissolve()

bool SG_Shape_Get_Dissolve ( CSG_Shape pPolygon,
CSG_Shape pResult 
)

Assuming supplied shape object is of type polygon and has several parts, it is important that the point order of outer rings (i.e. not lakes) is clockwise, that of lakes counter-clockwise to be processed correctly by the Clipper dissolve function. This is in accordance with the simple features definition but in contrast to ESRI's Shapefile format.

Definition at line 414 of file shapes_polygons.cpp.

References CSG_Shape::Get_Extent().

◆ SG_Shape_Get_ExclusiveOr()

◆ SG_Shape_Get_Intersection()

◆ SG_Shape_Get_Offset()

bool SG_Shape_Get_Offset ( CSG_Shape pPolygon,
double  dSize,
double  dArc,
CSG_Shape pResult 
)

◆ SG_Shape_Get_Union()