CGAL 5.1.2 - 2D Movable Separability of Sets
|
These function determine whether a cavity (of a mold in the plane) that has the shape of a given polygon could be casted in the mold and then pulled out of the mold without colliding into the mold (but possibly sliding along the mold boundary).
Functions | |
template<typename CastingTraits_2 , typename OutputIterator > | |
OutputIterator | CGAL::Set_movable_separability_2::Single_mold_translational_casting::top_edges (const CGAL::Polygon_2< CastingTraits > &polygon, OutputIterator oi, CastingTraits_2 &traits=CastingTraits_2()) |
Given a simple polygon, this function determines whether a cavity (of a mold in the plane) that has the shape of the polygon can be used so that the polygon could be casted in the mold and then pulled out of the mold without colliding into the mold (but possibly sliding along the mold surface). More... | |
template<typename CastingTraits_2 , typename OutputIterator > | |
OutputIterator | CGAL::Set_movable_separability_2::Single_mold_translational_casting::top_edges (const CGAL::Polygon_2< CastingTraits > &polygon, OutputIterator oi, CGAL::Orientation orientation, CastingTraits_2 &traits=CastingTraits_2()) |
Same as above with the additional orientation argument. More... | |
OutputIterator CGAL::Set_movable_separability_2::Single_mold_translational_casting::top_edges | ( | const CGAL::Polygon_2< CastingTraits > & | polygon, |
OutputIterator | oi, | ||
CastingTraits_2 & | traits = CastingTraits_2() |
||
) |
#include <CGAL/Set_movable_separability_2/Single_mold_translational_casting/top_edges.h>
Given a simple polygon, this function determines whether a cavity (of a mold in the plane) that has the shape of the polygon can be used so that the polygon could be casted in the mold and then pulled out of the mold without colliding into the mold (but possibly sliding along the mold surface).
If the polygon is castable, the function computes the set of top edges of such cavities and the corresponding closed ranges of pullout directions. Let \(n\) denote the normal to a top edge \(e\), and let \(d\) denote a pullout direction of \(e\). Naturally, the angle between \(n\) and \(d\) must be in the open range (-90°, 90°); that is, \(n \cdot d > 0\). Each top edge and corresponding range is added to a container referred to by a given output iterator.
The type that substitutes the template parameter CastingTraits_2
must be a model of the concept CastingTraits_2
.
polygon | the input polygon. |
oi | the output iterator. Its dereference type is a pair, where (i) the first element in the pair is an iterator to a top edge, and (ii) the second element is a closed range of pullout directions represented as a pair of the extreme directions in the range of type CastingTraits_2::Direction_2 . |
traits | the traits to use. |
polygon
must be non-degenerate (has at least 3 vertices) and simple, and it does not have three consecutive collinear vertices. OutputIterator CGAL::Set_movable_separability_2::Single_mold_translational_casting::top_edges | ( | const CGAL::Polygon_2< CastingTraits > & | polygon, |
OutputIterator | oi, | ||
CGAL::Orientation | orientation, | ||
CastingTraits_2 & | traits = CastingTraits_2() |
||
) |
#include <CGAL/Set_movable_separability_2/Single_mold_translational_casting/top_edges.h>
Same as above with the additional orientation
argument.
If the orientation of the polygon is known upon invocation, specify it. Otherwise, it has to be computed. Note that finding the orientation of a polygon requires time linear in the number of edges.
polygon | the input polygon. |
oi | the output iterator. Its dereference type is a pair, where (i) the first element in the pair is an iterator to a top edge, and (ii) the second element is a closed range of pullout directions represented as a pair of the extreme directions in the range of type CastingTraits_2::Direction_2 . |
orientation | the orientation of polygon . |
traits | the traits to use. |
polygon
must be non-degenerate (has at least 3 vertices) and simple, and it does not have three consecutive collinear vertices.