#include <CGAL/Scale_space_surface_reconstruction_3.h>
computes a triangulated surface mesh interpolating a point set.
Scale space reconstruction consists in combining a smoothing algorithm (see Scale_space_reconstruction_3::Smoother
) that is used to generate a user-specified number of scales with a meshing algorithm (see Scale_space_reconstruction_3::Mesher
).
The class stores the point set at the current scale and the reconstructed surface. User can either use the reconstructed surface at the current scale (smoothed version) or propagate the connectivity of the facets back to the original point set. This latest option makes it possible to reconstruct an interpolative surface on a noisy point set.
- Template Parameters
-
- Examples:
- Scale_space_reconstruction_3/scale_space.cpp, Scale_space_reconstruction_3/scale_space_advancing_front.cpp, Scale_space_reconstruction_3/scale_space_incremental.cpp, and Scale_space_reconstruction_3/scale_space_manifold.cpp.
|
typedef Geom_traits::FT | FT |
| defines the field number type.
|
|
typedef Geom_traits::Point_3 | Point |
| defines the point type.
|
|
typedef std::array< std::size_t, 3 > | Facet |
| defines a facet of the surface (triple of point indices).
|
|
typedef unspecified_type | Point_iterator |
| defines an iterator over the points.
|
|
typedef unspecified_type | Facet_iterator |
| defines an iterator over the points.
|
|
|
template<typename Smoother > |
void | increase_scale (std::size_t iterations=1, const Smoother &smoother=Smoother()) |
| increases the scale by a number of iterations. More...
|
|
template<typename Mesher > |
void | reconstruct_surface (const Mesher &mesher=Mesher()) |
| constructs a triangle mesh from the point set at a fixed scale. More...
|
|
◆ Scale_space_surface_reconstruction_3()
template<typename Geom_traits >
template<typename InputIterator >
Constructs a reconstruction object with the given point range.
- Note
- This constructor is equivalent to constructing an empty object and then calling
insert(begin, end)
.
- Template Parameters
-
InputIterator | is an iterator over the point collection. The value type of the iterator must be a Point . |
- Parameters
-
begin | is an iterator to the first point of the collection. |
end | is a past-the-end iterator for the point collection. |
◆ facets_begin()
template<typename Geom_traits >
gives an iterator to the first triple in the surface.
- Warning
- Changes to the surface may change its topology.
◆ facets_end()
template<typename Geom_traits >
gives a past-the-end iterator of the triples in the surface.
- Warning
- Changes to the surface may change its topology.
◆ increase_scale()
template<typename Geom_traits >
template<typename Smoother >
increases the scale by a number of iterations.
Each iteration the scale is increased, the points set at a higher scale is computed. At a higher scale, the points set is smoother.
- Note
- If no smoothing algorithm is specified, the default
Weighted_PCA_smoother
is used.
- Template Parameters
-
- Parameters
-
iterations | is the number of iterations to perform. If iterations is 0, nothing happens. |
smoother | the smoother object. |
- Note
- This method processes the point set at the current scale. The points can be set with
insert(begin, end)
.
-
If the surface was already constructed, increasing the scale will not automatically adjust the surface.
- See also
reconstruct_surface()
.
◆ insert() [1/2]
template<typename Geom_traits >
◆ insert() [2/2]
template<typename Geom_traits >
template<typename InputIterator >
inserts a collection of points into the scale-space at the current scale.
- Template Parameters
-
InputIterator | is an iterator over the point collection. The value type of the iterator must be a Point . |
- Parameters
-
begin | is an iterator to the first point of the collection. |
end | is a past-the-end iterator for the point collection. |
- Note
- Inserting the points does not automatically construct or update the surface.
-
In order to construct the surface, call
reconstruct_surface()
after inserting the points.
- See also
insert(const Point& p)
.
◆ points_begin()
template<typename Geom_traits >
gives an iterator to the first point at the current scale.
- Warning
- Changes to the scale-space do not cause an automatic update to the surface.
◆ points_end()
template<typename Geom_traits >
gives a past-the-end iterator of the points at the current scale.
- Warning
- Changes to the scale-space do not cause an automatic update to the surface.
◆ reconstruct_surface()
template<typename Geom_traits >
template<typename Mesher >
constructs a triangle mesh from the point set at a fixed scale.
The order of the points at the current scale is the same as the order at the original scale, meaning that the surface can interpolate the point set at the original scale by applying the indices of the surface triangles to the original point set.
After construction, the facets of the surface can be iterated using facets_begin()
and facets_end()
.
- Note
- If no meshing algorithm is specified, the default
Alpha_shape_mesher
is used.
- Template Parameters
-
- Parameters
-
- Note
- This method processes the point set at the current scale. The points can be set with
insert(begin, end)
.
- See also
increase_scale()
.