SFCGAL 2.0.0
|
Enumerations | |
enum | SFCGAL::algorithm::PartitionAlgorithm { SFCGAL::algorithm::y_monotone , SFCGAL::algorithm::approx_convex , SFCGAL::algorithm::greene_approx_convex , SFCGAL::algorithm::optimal_convex } |
Partition algorithm available. More... | |
enum | SFCGAL::GeometryType { SFCGAL::TYPE_POINT = 1 , SFCGAL::TYPE_LINESTRING = 2 , SFCGAL::TYPE_POLYGON = 3 , SFCGAL::TYPE_MULTIPOINT = 4 , SFCGAL::TYPE_MULTILINESTRING = 5 , SFCGAL::TYPE_MULTIPOLYGON = 6 , SFCGAL::TYPE_GEOMETRYCOLLECTION = 7 , SFCGAL::TYPE_POLYHEDRALSURFACE = 15 , SFCGAL::TYPE_TRIANGULATEDSURFACE = 16 , SFCGAL::TYPE_TRIANGLE = 17 , SFCGAL::TYPE_SOLID = 101 , SFCGAL::TYPE_MULTISOLID = 102 } |
[OGC/SFA]8.2.3 "A common list of codes for geometric types" More... | |
enum | SFCGAL::CoordinateType { SFCGAL::COORDINATE_XY = 0 , SFCGAL::COORDINATE_XYZ = 1000 , SFCGAL::COORDINATE_XYM = 2000 , SFCGAL::COORDINATE_XYZM = 3000 } |
coordinate types (XY, XYZ, XYM, etc.) More... |
Functions | |
auto | SFCGAL::algorithm::alphaShapes (const Geometry &g, double alpha=1, bool allow_holes=false) -> std::unique_ptr< Geometry > |
Compute the 2D alpha shapes for a geometry https://doc.cgal.org/latest/Alpha_shapes_2/index.html#Chapter_2D_Alpha_Shapes. | |
auto | SFCGAL::algorithm::optimal_alpha_shapes (const Geometry &g, bool allow_holes=false, size_t nb_components=1) -> std::unique_ptr< Geometry > |
Compute the optimal 2D alpha shapes for a geometry https://doc.cgal.org/latest/Alpha_shapes_2/index.html#Chapter_2D_Alpha_Shapes. | |
auto | SFCGAL::algorithm::area (const Geometry &g) |
Compute the 2D area for a Geometry. | |
auto | SFCGAL::algorithm::area3D (const Geometry &g) |
Returns 3D area for a Geometry. | |
auto | SFCGAL::algorithm::convexHull (const Geometry &g) |
Compute the 2D convex hull for a geometry. | |
auto | SFCGAL::algorithm::convexHull3D (const Geometry &g) |
Compute the 3D convex hull for a geometry. | |
auto | SFCGAL::algorithm::difference (const Geometry &ga, const Geometry &gb) |
Difference on 2D geometries. | |
auto | SFCGAL::algorithm::difference3D (const Geometry &ga, const Geometry &gb) |
Difference on 3D geometries. | |
auto | SFCGAL::algorithm::distance (const Geometry &gA, const Geometry &gB) |
Compute the distance between two Geometries. | |
auto | SFCGAL::algorithm::distance3D (const Geometry &gA, const Geometry &gB) |
dispatch distance between two Geometries | |
auto | SFCGAL::algorithm::extrude (const Geometry &g, const Kernel::FT &dx, const Kernel::FT &dy, const Kernel::FT &dz) |
Returns a Geometry equal to the specified Geometry, extruded by the specified displacement. | |
auto | SFCGAL::algorithm::intersection (const Geometry &ga, const Geometry &gb) |
Intersection on 2D geometries. | |
auto | SFCGAL::algorithm::intersection3D (const Geometry &ga, const Geometry &gb) |
Intersection on 3D geometries. | |
auto | SFCGAL::algorithm::intersects (const Geometry &ga, const Geometry &gb) |
Robust intersection test on 2D geometries. | |
auto | SFCGAL::algorithm::intersects3D (const Geometry &ga, const Geometry &gb) |
Robust intersection test on 3D geometries. | |
auto | SFCGAL::algorithm::isValid (const Geometry &g, const double &toleranceAbs=1e-9) |
Check validity of a geometry. | |
void | SFCGAL::algorithm::propagateValidityFlag (Geometry &g, bool valid) |
Sets the geometry flag on a geometry and propagate to every internal geometries. | |
auto | SFCGAL::algorithm::minkowskiSum (const Geometry &gA, const Polygon &gB) |
2D minkowski sum (p+q) | |
auto | SFCGAL::algorithm::minkowskiSum3D (const Geometry &gA, const Geometry &gB) |
3D Minkowski sum (p+q) | |
auto | SFCGAL::algorithm::offset (const Geometry &g, const double &r) |
[experimental]compute polygon offset | |
auto | SFCGAL::algorithm::partition_2 (const Geometry &g, PartitionAlgorithm alg=y_monotone) -> std::unique_ptr< Geometry > |
Compute the partition of a 2D polygon https://doc.cgal.org/latest/Partition_2/index.html#Chapter_2D_Polygon_Partitioning. | |
template<typename Kernel> | |
bool | SFCGAL::algorithm::hasPlane3D (const Polygon &polygon, CGAL::Point_3< Kernel > &a, CGAL::Point_3< Kernel > &b, CGAL::Point_3< Kernel > &c) |
Test if a 3D plane can be extracted from a Polygon. | |
auto | SFCGAL::algorithm::approximateMedialAxis (const Geometry &g) |
build an approximate medial axis for a Polygon | |
auto | SFCGAL::algorithm::straightSkeleton (const Geometry &g, bool autoOrientation=true, bool innerOnly=false, bool outputDistanceInM=false, const double &toleranceAbs=1e-8) |
build a 2D straight skeleton for a Polygon | |
auto | SFCGAL::algorithm::straightSkeleton (const Geometry &g, bool autoOrientation, NoValidityCheck, bool innerOnly=false, bool outputDistanceInM=false, const double &toleranceAbs=1e-8) |
build a 2D straight skeleton for a Polygon | |
auto | SFCGAL::algorithm::straightSkeletonPartition (const Geometry &g, bool autoOrientation=true) |
Build a 2D straight skeleton partition for a Geometry. | |
auto | SFCGAL::algorithm::tesselate (const Geometry &) |
Tesselate a geometry: this will triangulate surfaces (including polyhedral and solid's surfaces) and keep untouched points, lines, etc. | |
auto | SFCGAL::algorithm::union_ (const Geometry &ga, const Geometry &gb) |
Union on 2D geometries. | |
auto | SFCGAL::algorithm::union3D (const Geometry &ga, const Geometry &gb) |
Union on 3D geometries. | |
auto | SFCGAL::algorithm::visibility (const Geometry &polygon, const Geometry &point) -> std::unique_ptr< Polygon > |
build the visibility polygon of a Point inside a Polygon | |
auto | SFCGAL::algorithm::visibility (const Geometry &polygon, const Geometry &point, NoValidityCheck) -> std::unique_ptr< Polygon > |
build the visibility polygon of a Point inside a Polygon | |
auto | SFCGAL::algorithm::visibility (const Geometry &polygon, const Geometry &pointA, const Geometry &pointB) -> std::unique_ptr< Polygon > |
build the visibility polygon of the segment [pointA ; pointB] on a Polygon | |
auto | SFCGAL::algorithm::visibility (const Geometry &polygon, const Geometry &pointA, const Geometry &pointB, NoValidityCheck) -> std::unique_ptr< Polygon > |
build the visibility polygon of a Point inside a Polygon | |
auto | SFCGAL::algorithm::volume (const Geometry &g) |
Computes the volume of a geometry. | |
SFCGAL_API sfcgal_geometry_t * | sfcgal_geometry_visibility_segment (const sfcgal_geometry_t *polygon, const sfcgal_geometry_t *pointA, const sfcgal_geometry_t *pointB) |
build the visibility polygon of the segment [pointA ; pointB] on a Polygon |
enum SFCGAL::GeometryType |
[OGC/SFA]8.2.3 "A common list of codes for geometric types"
Partition algorithm available.
Enumerator | |
---|---|
y_monotone | Y Monotone Partition: https://doc.cgal.org/latest/Partition_2/index.html#secpartition_2_monotone |
approx_convex | Simple approximation algorithm of Hertel and Mehlhorn https://doc.cgal.org/latest/Partition_2/index.html#secpartition_2_convex |
greene_approx_convex | Sweep-line approximation algorithm of Greene https://doc.cgal.org/latest/Partition_2/index.html#secpartition_2_convex |
optimal_convex | Optimal convex partition https://doc.cgal.org/latest/Partition_2/index.html#secpartition_2_convex |
SFCGAL_API auto SFCGAL::algorithm::alphaShapes | ( | const Geometry & | g, |
double | alpha = 1, | ||
bool | allow_holes = false ) -> std::unique_ptr< Geometry > |
Compute the 2D alpha shapes for a geometry https://doc.cgal.org/latest/Alpha_shapes_2/index.html#Chapter_2D_Alpha_Shapes.
SFCGAL_API std::unique_ptr< MultiLineString > SFCGAL::algorithm::approximateMedialAxis | ( | const Geometry & | g | ) |
build an approximate medial axis for a Polygon
g | input geometry |
NotImplementedException | If g is a Polygon with point touching rings. |
SFCGAL_API double SFCGAL::algorithm::area | ( | const Geometry & | g | ) |
Compute the 2D area for a Geometry.
SFCGAL_API double SFCGAL::algorithm::area3D | ( | const Geometry & | g | ) |
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::convexHull | ( | const Geometry & | g | ) | -> std::unique_ptr< Geometry > |
Compute the 2D convex hull for a geometry.
Compute the 3D convex hull for a geometry.
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::difference | ( | const Geometry & | ga, |
const Geometry & | gb ) |
Difference on 2D geometries.
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::difference3D | ( | const Geometry & | ga, |
const Geometry & | gb ) |
Difference on 3D geometries.
Assume z = 0 if needed
Compute the distance between two Geometries.
dispatch distance between two Geometries
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::extrude | ( | const Geometry & | g, |
const Kernel::FT & | dx, | ||
const Kernel::FT & | dy, | ||
const Kernel::FT & | dz ) |
Returns a Geometry equal to the specified Geometry, extruded by the specified displacement.
g | The specified Geometry. |
dx | The component of the specified displacement in the x-direction. |
dy | The component of the specified displacement in the y-direction. |
dz | The component of the specified displacement in the z-direction. |
bool SFCGAL::algorithm::hasPlane3D | ( | const Polygon & | polygon, |
CGAL::Point_3< Kernel > & | a, | ||
CGAL::Point_3< Kernel > & | b, | ||
CGAL::Point_3< Kernel > & | c ) |
Test if a 3D plane can be extracted from a Polygon.
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::intersection | ( | const Geometry & | ga, |
const Geometry & | gb ) |
Intersection on 2D geometries.
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::intersection3D | ( | const Geometry & | ga, |
const Geometry & | gb ) |
Intersection on 3D geometries.
Assume z = 0 if needed
Robust intersection test on 2D geometries.
Force projection to z=0 if needed
Robust intersection test on 3D geometries.
Assume z = 0 if needed
SFCGAL_API const Validity SFCGAL::algorithm::isValid | ( | const Geometry & | g, |
const double & | toleranceAbs ) -> const Validity |
Check validity of a geometry.
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::minkowskiSum | ( | const Geometry & | gA, |
const Polygon & | gB ) |
2D minkowski sum (p+q)
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::minkowskiSum3D | ( | const Geometry & | gA, |
const Geometry & | gB ) |
3D Minkowski sum (p+q)
SFCGAL_API std::unique_ptr< MultiPolygon > SFCGAL::algorithm::offset | ( | const Geometry & | g, |
const double & | r ) |
[experimental]compute polygon offset
SFCGAL_API auto SFCGAL::algorithm::optimal_alpha_shapes | ( | const Geometry & | g, |
bool | allow_holes = false, | ||
size_t | nb_components = 1 ) -> std::unique_ptr< Geometry > |
Compute the optimal 2D alpha shapes for a geometry https://doc.cgal.org/latest/Alpha_shapes_2/index.html#Chapter_2D_Alpha_Shapes.
SFCGAL_API auto SFCGAL::algorithm::partition_2 | ( | const Geometry & | g, |
PartitionAlgorithm | alg = y_monotone ) -> std::unique_ptr< Geometry > |
Compute the partition of a 2D polygon https://doc.cgal.org/latest/Partition_2/index.html#Chapter_2D_Polygon_Partitioning.
SFCGAL_API void SFCGAL::algorithm::propagateValidityFlag | ( | Geometry & | g, |
bool | valid ) |
Sets the geometry flag on a geometry and propagate to every internal geometries.
SFCGAL_API sfcgal_geometry_t * sfcgal_geometry_visibility_segment | ( | const sfcgal_geometry_t * | polygon, |
const sfcgal_geometry_t * | pointA, | ||
const sfcgal_geometry_t * | pointB ) |
build the visibility polygon of the segment [pointA ; pointB] on a Polygon
polygon | input geometry |
pointA | input geometry |
pointB | input geometry |
SFCGAL_API std::unique_ptr< MultiLineString > SFCGAL::algorithm::straightSkeleton | ( | const Geometry & | g, |
bool | autoOrientation, | ||
NoValidityCheck | , | ||
bool | innerOnly = false, | ||
bool | outputDistanceInM = false, | ||
const double & | toleranceAbs = 1e-8 ) |
build a 2D straight skeleton for a Polygon
g | input geometry |
autoOrientation | check and fix polygon orientation |
outputM | whether to output the distance to border as M |
toleranceAbs | Distance tolerance between returned points. A line must have a maximum distance of toleranceAbs. |
NotImplementedException | If g is a Polygon with point touching rings. |
SFCGAL_API std::unique_ptr< MultiLineString > SFCGAL::algorithm::straightSkeleton | ( | const Geometry & | g, |
bool | autoOrientation = true, | ||
bool | innerOnly = false, | ||
bool | outputDistanceInM = false, | ||
const double & | toleranceAbs = 1e-8 ) |
build a 2D straight skeleton for a Polygon
g | input geometry |
autoOrientation | check and fix polygon orientation |
outputM | whether to output the distance to border as M |
toleranceAbs | Distance tolerance between returned points. A line must have a maximum distance of toleranceAbs. |
NotImplementedException | If g is a Polygon with point touching rings. |
SFCGAL_API std::unique_ptr< MultiPolygon > SFCGAL::algorithm::straightSkeletonPartition | ( | const Geometry & | g, |
bool | autoOrientation = true ) |
Build a 2D straight skeleton partition for a Geometry.
[in] | g | The input geometry |
[in] | autoOrientation | Check and fix polygon orientation |
Exception | If CGAL fails to create the straight skeleton |
This function creates a partition of the input geometry based on its straight skeleton. For unsupported geometry types, an empty MultiPolygon is returned.
SFCGAL_API std::unique_ptr< SFCGAL::Geometry > SFCGAL::algorithm::tesselate | ( | const Geometry & | ) |
Tesselate a geometry: this will triangulate surfaces (including polyhedral and solid's surfaces) and keep untouched points, lines, etc.
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::union3D | ( | const Geometry & | ga, |
const Geometry & | gb ) |
Union on 3D geometries.
Assume z = 0 if needed
SFCGAL_API std::unique_ptr< Geometry > SFCGAL::algorithm::union_ | ( | const Geometry & | ga, |
const Geometry & | gb ) |
Union on 2D geometries.
SFCGAL_API auto SFCGAL::algorithm::visibility | ( | const Geometry & | polygon, |
const Geometry & | point, | ||
NoValidityCheck | ) -> std::unique_ptr< Polygon > |
SFCGAL_API auto SFCGAL::algorithm::visibility | ( | const Geometry & | polygon, |
const Geometry & | pointA, | ||
const Geometry & | pointB ) -> std::unique_ptr< Polygon > |
build the visibility polygon of the segment [pointA ; pointB] on a Polygon
polygon | input geometry |
pointA | input geometry |
pointB | input geometry |
SFCGAL_API auto SFCGAL::algorithm::visibility | ( | const Geometry & | polygon, |
const Geometry & | pointA, | ||
const Geometry & | pointB, | ||
NoValidityCheck | ) -> std::unique_ptr< Polygon > |
build the visibility polygon of a Point inside a Polygon
polygon | input geometry |
pointA | input geometry |
pointB | input geometry |