MeshDomainWithFeatures_3

Definition

The concept MeshDomainWithFeatures_3 refines the concept MeshDomain_3. While the concept MeshDomain_3 only exposes the 2-dimensional and 3-dimensional features of the domain through different queries, the concept MeshDomainWithFeatures_3 also exposes 0 and 1-dimensional features. The exposed features of the domain are respectively called subdomains, surface patches, curve segments and corners according to their respective dimensions 3,2,1 and 0.

Refines

MeshDomain_3

Types

typedef CGAL::Tag_true Has_features; A type to distinguish MeshDomain_3 models from MeshDomainWithFeatures_3 models.

MeshDomainWithFeatures_3::FT
Numerical type.


MeshDomainWithFeatures_3::Curve_segment_index
Type of indices for curve segments (1-dimensional features) of the input domain. Must be a model of CopyConstructible, Assignable, DefaultConstructible and LessThanComparable. The default constructed value must be the value of an edge which does not approximate a 1-dimensional feature of the input domain.


MeshDomainWithFeatures_3::Corner_index
Type of indices for corners (i.e. 0-dimensional features) of the input domain. Must be a model of CopyConstructible, Assignable, DefaultConstructible and LessThanComparable.

Operations

Each connected component of a curve segment is assumed to be oriented. The orientation is defined by the ordering of the two incident corners at the origin and endpoint. Therefore it is possible to defined the signed geodesic distance between two ordered points on the same connected component of a curve segment. A cycle is a connected component of a curve segment incident to 0 or 1 corner.

Point_3 md.construct_point_on_curve_segment ( Point_3 p, Curve_segment_index ci, FT d) const
Returns a point on the curve segment with index ci at signed geodesic distance d from point p.
Precondition:  Point p is supposed to be on curve segment ci. If d > 0, the signed geodesic distance from p to the endpoint of the connected component of ci including p, should be greater than d. If d < 0, the signed geodesic distance from p to the origin of the connected component should be less than d from the origin of the connected component.

Note that construct_point_on_curve segment is assumed to return a uniquely defined point. Therefore it is not possible to handle as a single curve segment, a singular curve with several branches incident to the same point.

Queries

FT md.geodesic_distance ( Point_3 p, Point_3 q, Curve_segment_index ci) const
Returns the signed geodesic distance between points p and q along the input curve segment with index ci.
Precondition: Points p and q belong to the same connected component of the curve segment with index ci.

CGAL::Sign md.distance_sign_along_cycle ( Point_3 p, Point_3 q, Point_3 r, Curve_segment_index ci) const
Returns CGAL::POSITIVE if the signed geodesic distance from p to q on the way through r along cycle with index ci is positive, CGAL::NEGATIVE if the distance is negative, and CGAL::ZERO if (p = q = r).
Precondition: Points p, q and r belongs to the same connected component of curve segment ci and this component is a cycle.

bool md.is_cycle ( Point_3 p, Curve_segment_index ci) const
Returns true if the connected component of curve segment ci including point p is a cycle.

Retrieval of the input features and their incidences

template <typename OutputIterator>
OutputIterator md.get_corners ( OutputIterator corners) const
Fills corners with the corners of the input domain. corners value type must be std::pair<Corner_index,Point_3>.

template <typename OutputIterator>
OutputIterator md.get_curve_segments ( OutputIterator curves) const
Fills curves with the curve segments of the input domain. curves value type must be CGAL::cpp0x::tuple<Curve_segment_index,std::pair<Point_3,Index>,std::pair<Point_3,Index> >. If the curve segment corresponding to an entry in curves is not a cycle, the pair of associated points should belong to two corners incident on the curve segment. If it is a cycle, then the same Point_3 should be given twice and must be any point on the cycle. The Index values associated to the points are their indices w.r.t. their dimension.

bool md.are_incident_surface_patch_curve_segment ( Surface_patch_index spi, Curve_segment_index csi)
Returns true if the curve segment with index csi is incident to the surface patch with index spi.

bool md.are_incident_surface_patch_corner ( Surface_patch_index spi, Corner_index ci)
Returns true if the corner with index ci is incident to the surface patch with index spi.

Indices converters

Index md.index_from_curve_segment_index ( Curve_segment_index curve_segment_index) const
Returns the index to be stored at a vertex lying on the curve segment identified by curve_segment_index.
Curve_segment_index md.curve_segment_index ( Index index) const
Returns the Curve_segment_index of the curve segment where lies a vertex with dimension 1 and index index.

Index md.index_from_corner_index ( Corner_index corner_index) const
Returns the index to be stored at a vertex lying on the corner identified by corner_index.
Corner_index md.corner_index ( Index index) const
Returns the Corner_index of the corner where lies a vertex with dimension 0 and index index.

Has Models

Mesh_domain_with_polyline_features_3<MeshDomain_3>
Polyhedral_mesh_domain_with_features_3<IGT>

See Also

MeshDomain_3