mirror of https://github.com/CGAL/cgal
Uniformized between Mesh_3::internal and internal::Mesh_3
This commit is contained in:
parent
e996e173da
commit
1078e00e7f
|
|
@ -29,9 +29,9 @@
|
|||
#include <CGAL/tags.h>
|
||||
|
||||
namespace CGAL {
|
||||
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
// A type has_Has_features to check if type 'Has_features' is a nested
|
||||
// type of any class
|
||||
BOOST_MPL_HAS_XXX_TRAIT_DEF(Has_features)
|
||||
|
|
@ -47,8 +47,9 @@ namespace Mesh_3 {
|
|||
struct Has_features<Mesh_domain, false> : public CGAL::Tag_false
|
||||
// when Mesh_domain does not have the nested type Has_features
|
||||
{};
|
||||
} // end namespace internal::Mesh_3
|
||||
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
} // end namespace CGAL
|
||||
|
||||
#endif // CGAL_MESH_3_HAS_FEATURES_H
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ void init_tr_from_labeled_image_call_init_features(C3T3& c3t3,
|
|||
const MeshCriteria& criteria,
|
||||
CGAL::Tag_true)
|
||||
{
|
||||
CGAL::internal::Mesh_3::init_c3t3_with_features(c3t3,
|
||||
CGAL::Mesh_3::internal::init_c3t3_with_features(c3t3,
|
||||
domain,
|
||||
criteria);
|
||||
std::cout << c3t3.triangulation().number_of_vertices()
|
||||
|
|
@ -110,7 +110,7 @@ void initialize_triangulation_from_labeled_image(C3T3& c3t3,
|
|||
if(protect_features) {
|
||||
init_tr_from_labeled_image_call_init_features
|
||||
(c3t3, domain, criteria,
|
||||
CGAL::internal::Mesh_3::Has_features<Mesh_domain>());
|
||||
CGAL::Mesh_3::internal::Has_features<Mesh_domain>());
|
||||
}
|
||||
|
||||
const double max_v = (std::max)((std::max)(image.vx(),
|
||||
|
|
@ -250,7 +250,7 @@ void initialize_triangulation_from_labeled_image(C3T3& c3t3,
|
|||
{
|
||||
std::cout << " not enough points: triangulation.dimension() == "
|
||||
<< c3t3.triangulation().dimension() << std::endl;
|
||||
CGAL::internal::Mesh_3::init_c3t3(c3t3, domain, criteria, 20);
|
||||
CGAL::Mesh_3::internal::init_c3t3(c3t3, domain, criteria, 20);
|
||||
std::cout << " -> " << tr.number_of_vertices() << " initial points." << std::endl;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -198,7 +198,7 @@ polylines_to_protect(const CGAL::Image_3& cgal_image,
|
|||
const int image_dims[3] = { xdim, ydim, zdim };
|
||||
|
||||
Graph graph;
|
||||
internal::Mesh_3::Graph_manipulations<Graph, Point_3> g_manip(graph);
|
||||
Mesh_3::internal::Graph_manipulations<Graph, Point_3> g_manip(graph);
|
||||
|
||||
std::size_t
|
||||
case4 = 0, // 4 colors
|
||||
|
|
@ -571,7 +571,7 @@ polylines_to_protect(std::vector<std::vector<P> >& polylines,
|
|||
typedef typename std::iterator_traits<PolylineInputIterator>::value_type Polyline;
|
||||
|
||||
Graph graph;
|
||||
internal::Mesh_3::Graph_manipulations<Graph, Point_3> g_manip(graph);
|
||||
Mesh_3::internal::Graph_manipulations<Graph, Point_3> g_manip(graph);
|
||||
|
||||
for (PolylineInputIterator poly_it = existing_polylines_begin;
|
||||
poly_it != existing_polylines_end; ++poly_it)
|
||||
|
|
|
|||
|
|
@ -33,7 +33,6 @@
|
|||
#include <sstream>
|
||||
|
||||
namespace CGAL {
|
||||
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
|
|
@ -125,8 +124,6 @@ public:
|
|||
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
|
||||
|
||||
} //namespace CGAL
|
||||
|
||||
#endif // CGAL_MESH_3_UTILITIES_H
|
||||
|
|
|
|||
|
|
@ -50,8 +50,8 @@
|
|||
namespace CGAL {
|
||||
|
||||
/// @cond DEVELOPERS
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template <typename Kernel>
|
||||
class Polyline
|
||||
|
|
@ -509,8 +509,8 @@ struct Display_incidences_to_curves_aux<MDwPF, false> {
|
|||
const Container&) const;
|
||||
};
|
||||
|
||||
} // end of namespace CGAL::internal::Mesh_3
|
||||
} // end of namespace CGAL::internal
|
||||
} // end of namespace CGAL::Mesh_3
|
||||
/// @endcond
|
||||
|
||||
/*!
|
||||
|
|
@ -843,13 +843,13 @@ private:
|
|||
private:
|
||||
typedef std::map<Point_3,Corner_index> Corners;
|
||||
|
||||
typedef internal::Mesh_3::Polyline<Gt> Polyline;
|
||||
typedef Mesh_3::internal::Polyline<Gt> Polyline;
|
||||
typedef std::map<Curve_index, Polyline> Edges;
|
||||
typedef std::map<Curve_index, Surface_patch_index_set > Edges_incidences;
|
||||
typedef std::map<Corner_index, std::set<Curve_index> > Corners_tmp_incidences;
|
||||
typedef std::map<Corner_index, Surface_patch_index_set > Corners_incidences;
|
||||
|
||||
typedef internal::Mesh_3::Mesh_domain_segment_of_curve_primitive<
|
||||
typedef Mesh_3::internal::Mesh_domain_segment_of_curve_primitive<
|
||||
Gt,
|
||||
typename Edges::const_iterator> Curves_primitives;
|
||||
|
||||
|
|
@ -1271,8 +1271,8 @@ get_corner_incident_curves(Corner_index id,
|
|||
/// @endcond
|
||||
|
||||
/// @cond DEVELOPERS
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template <typename MDwPF_, bool curve_id_is_streamable>
|
||||
// here 'curve_id_is_streamable' is true
|
||||
|
|
@ -1337,7 +1337,8 @@ operator()(std::ostream& os, Point p, typename MDwPF_::Curve_index id,
|
|||
<< " surface patch(es).\n";
|
||||
}
|
||||
|
||||
}} // end namespaces internal::Mesh_3:: and internal::
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
/// @endcond
|
||||
|
||||
/// @cond DEVELOPERS
|
||||
|
|
@ -1350,7 +1351,7 @@ display_corner_incidences(std::ostream& os, Point_3 p, Corner_index id)
|
|||
typedef is_streamable<Surface_patch_index> i_s_spi;
|
||||
typedef is_streamable<Curve_index> i_s_csi;
|
||||
|
||||
using namespace internal::Mesh_3;
|
||||
using namespace Mesh_3::internal;
|
||||
typedef Display_incidences_to_curves_aux<Mdwpf,i_s_csi::value> D_i_t_c;
|
||||
typedef Display_incidences_to_patches_aux<Mdwpf,i_s_spi::value> D_i_t_p;
|
||||
D_i_t_c()(os, p, id, corners_tmp_incidences_[id]);
|
||||
|
|
|
|||
|
|
@ -32,9 +32,8 @@
|
|||
#include <boost/type_traits.hpp>
|
||||
|
||||
namespace CGAL {
|
||||
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
// Those two classes are designed to handle dynamic initialization of
|
||||
// Sizing_field type (using named parameters of make_mesh_3 for example)
|
||||
|
|
@ -92,7 +91,8 @@ namespace Mesh_3 {
|
|||
Sizing_field s_;
|
||||
};
|
||||
|
||||
}} // end namespace internal::Mesh_3
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
|
||||
template < typename Tr >
|
||||
class Mesh_edge_criteria_3
|
||||
|
|
@ -107,7 +107,7 @@ public:
|
|||
|
||||
/// Constructors
|
||||
Mesh_edge_criteria_3(const FT& value)
|
||||
: p_size_(new internal::Mesh_3::Sizing_field_container<
|
||||
: p_size_(new Mesh_3::internal::Sizing_field_container<
|
||||
Mesh_constant_domain_field_3<Gt,Index> >(value))
|
||||
{}
|
||||
|
||||
|
|
@ -124,7 +124,7 @@ public:
|
|||
CGAL_static_assertion((boost::is_same<typename Sizing_field::Index,
|
||||
Index>::value));
|
||||
|
||||
p_size_ = new internal::Mesh_3::Sizing_field_container<Sizing_field>(size);
|
||||
p_size_ = new Mesh_3::internal::Sizing_field_container<Sizing_field>(size);
|
||||
}
|
||||
|
||||
Mesh_edge_criteria_3(const Self& rhs)
|
||||
|
|
@ -141,7 +141,7 @@ public:
|
|||
{ return (*p_size_)(p,dim,index); }
|
||||
|
||||
private:
|
||||
typedef internal::Mesh_3::Sizing_field_interface<FT,Point_3,Index>
|
||||
typedef Mesh_3::internal::Sizing_field_interface<FT,Point_3,Index>
|
||||
Sizing_field_interface;
|
||||
|
||||
// A pointer to Sizing_field_interface to handle dynamic wrapping of
|
||||
|
|
|
|||
|
|
@ -281,7 +281,7 @@ operator>>(std::istream &is, Mesh_vertex_base_3<GT,MD,Vb>& v)
|
|||
CGAL_assertion(v.in_dimension() >= -1);
|
||||
CGAL_assertion(v.in_dimension() < 4);
|
||||
typename Vertex::Index index =
|
||||
internal::Mesh_3::Read_mesh_domain_index<MD>()(v.in_dimension(), is);
|
||||
Mesh_3::internal::Read_mesh_domain_index<MD>()(v.in_dimension(), is);
|
||||
v.set_index(index);
|
||||
return is;
|
||||
}
|
||||
|
|
@ -302,7 +302,7 @@ operator<<(std::ostream &os, const Mesh_vertex_base_3<GT,MD,Vb>& v)
|
|||
} else {
|
||||
CGAL::write(os, v.in_dimension());
|
||||
}
|
||||
internal::Mesh_3::Write_mesh_domain_index<MD>()(os,
|
||||
Mesh_3::internal::Write_mesh_domain_index<MD>()(os,
|
||||
v.in_dimension(),
|
||||
v.index());
|
||||
return os;
|
||||
|
|
|
|||
|
|
@ -57,8 +57,8 @@
|
|||
|
||||
namespace CGAL {
|
||||
/// @cond DEVELOPERS
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template <typename Graph>
|
||||
void dump_graph_edges(std::ostream& out, const Graph& g)
|
||||
|
|
@ -202,8 +202,8 @@ struct Extract_polyline_with_context_visitor
|
|||
};
|
||||
|
||||
|
||||
} // end CGAL::internal::Mesh_3
|
||||
} // end CGAL::internal
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
|
||||
/// @endcond
|
||||
|
||||
|
|
@ -889,7 +889,7 @@ detect_features(FT angle_in_degree,
|
|||
BOOST_FOREACH(Polyhedron_type& p, poly)
|
||||
{
|
||||
initialize_ts(p);
|
||||
using internal::Mesh_3::Get_face_index_pmap;
|
||||
using Mesh_3::internal::Get_face_index_pmap;
|
||||
Get_face_index_pmap<Polyhedron_type> get_face_index_pmap(p);
|
||||
#ifdef CGAL_MESH_3_VERBOSE
|
||||
std::size_t poly_id = &p-&poly[0];
|
||||
|
|
@ -911,7 +911,7 @@ detect_features(FT angle_in_degree,
|
|||
.vertex_incident_patches_map(vip_map)
|
||||
.vertex_feature_degree_map(vertex_feature_degree_map));
|
||||
|
||||
internal::Mesh_3::Is_featured_edge<Polyhedron_type> is_featured_edge(p);
|
||||
Mesh_3::internal::Is_featured_edge<Polyhedron_type> is_featured_edge(p);
|
||||
|
||||
add_featured_edges_to_graph(p, is_featured_edge, g_copy, p2vmap);
|
||||
}
|
||||
|
|
@ -1034,12 +1034,12 @@ add_features_from_split_graph_into_polylines(Featured_edges_copy_graph& g_copy)
|
|||
{
|
||||
std::vector<Polyline_with_context> polylines;
|
||||
|
||||
internal::Mesh_3::Extract_polyline_with_context_visitor<
|
||||
Mesh_3::internal::Extract_polyline_with_context_visitor<
|
||||
Polyhedral_complex_mesh_domain_3,
|
||||
Polyline_with_context,
|
||||
Featured_edges_copy_graph
|
||||
> visitor(g_copy, polylines);
|
||||
internal::Mesh_3::Angle_tester<GT_> angle_tester;
|
||||
Mesh_3::internal::Angle_tester<GT_> angle_tester;
|
||||
split_graph_into_polylines(g_copy, visitor, angle_tester);
|
||||
|
||||
this->add_features_with_context(polylines.begin(),
|
||||
|
|
@ -1120,7 +1120,7 @@ add_featured_edges_to_graph(const Polyhedron_type& p,
|
|||
|
||||
#if CGAL_MESH_3_PROTECTION_DEBUG > 1
|
||||
{// DEBUG
|
||||
internal::Mesh_3::dump_graph_edges("edges-graph.polylines.txt", g_copy);
|
||||
Mesh_3::internal::dump_graph_edges("edges-graph.polylines.txt", g_copy);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
|
|
|||
|
|
@ -127,11 +127,10 @@ struct IGT_generator<Gt,CGAL::Tag_false>
|
|||
};
|
||||
|
||||
} // end namespace details
|
||||
|
||||
} // end namespace Mesh_3
|
||||
|
||||
|
||||
namespace internal { namespace Mesh_3 {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template <typename Polyhedron_type,
|
||||
bool = boost::graph_has_property<Polyhedron_type,
|
||||
|
|
@ -168,8 +167,8 @@ private:
|
|||
Map face_ids;
|
||||
};
|
||||
|
||||
} // end namespace Mesh_3
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
|
||||
/**
|
||||
* @class Polyhedral_mesh_domain_3
|
||||
|
|
|
|||
|
|
@ -60,9 +60,8 @@
|
|||
|
||||
|
||||
namespace CGAL {
|
||||
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template <typename Kernel>
|
||||
struct Angle_tester
|
||||
|
|
@ -184,8 +183,8 @@ struct Extract_polyline_with_context_visitor
|
|||
};
|
||||
|
||||
|
||||
} // end CGAL::internal::Mesh_3
|
||||
} // end CGAL::internal
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
|
||||
/**
|
||||
* @class Polyhedral_mesh_domain_with_features_3
|
||||
|
|
@ -463,7 +462,7 @@ detect_features(FT angle_in_degree, std::vector<Polyhedron>& poly)
|
|||
typedef typename boost::property_map<Polyhedron,CGAL::vertex_incident_patches_t<P_id> >::type VIPMap;
|
||||
typedef typename boost::property_map<Polyhedron, CGAL::edge_is_feature_t>::type EIFMap;
|
||||
|
||||
using internal::Mesh_3::Get_face_index_pmap;
|
||||
using Mesh_3::internal::Get_face_index_pmap;
|
||||
Get_face_index_pmap<Polyhedron> get_face_index_pmap(p);
|
||||
|
||||
PIDMap pid_map = get(face_patch_id_t<Tag_>(), p);
|
||||
|
|
@ -478,7 +477,7 @@ detect_features(FT angle_in_degree, std::vector<Polyhedron>& poly)
|
|||
.face_index_map(get_face_index_pmap(p))
|
||||
.vertex_incident_patches_map(vip_map));
|
||||
|
||||
internal::Mesh_3::Is_featured_edge<Polyhedron> is_featured_edge(p);
|
||||
Mesh_3::internal::Is_featured_edge<Polyhedron> is_featured_edge(p);
|
||||
|
||||
add_featured_edges_to_graph(p, is_featured_edge, g_copy, p2vmap);
|
||||
}
|
||||
|
|
@ -508,12 +507,12 @@ add_features_from_split_graph_into_polylines(Featured_edges_copy_graph& g_copy)
|
|||
{
|
||||
std::vector<Polyline_with_context> polylines;
|
||||
|
||||
internal::Mesh_3::Extract_polyline_with_context_visitor<
|
||||
Mesh_3::internal::Extract_polyline_with_context_visitor<
|
||||
Polyhedral_mesh_domain_with_features_3,
|
||||
Polyline_with_context,
|
||||
Featured_edges_copy_graph
|
||||
> visitor(g_copy, polylines);
|
||||
internal::Mesh_3::Angle_tester<GT_> angle_tester;
|
||||
Mesh_3::internal::Angle_tester<GT_> angle_tester;
|
||||
split_graph_into_polylines(g_copy, visitor, angle_tester);
|
||||
|
||||
this->add_features_with_context(polylines.begin(),
|
||||
|
|
|
|||
|
|
@ -33,8 +33,8 @@
|
|||
#include <map>
|
||||
|
||||
namespace CGAL {
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template <typename Graph, typename Point_3>
|
||||
struct Graph_manipulations
|
||||
|
|
@ -116,8 +116,8 @@ struct Graph_manipulations
|
|||
}
|
||||
}; // struct template Graph_manipulations
|
||||
|
||||
} // namespace Mesh_3
|
||||
} // namespace internal
|
||||
} // namespace Mesh_3
|
||||
} // namespace CGAL
|
||||
|
||||
#endif //CGAL_INTERNAL_MESH_3_INTERNAL_GRAPH_MANIPULATIONS
|
||||
|
|
|
|||
|
|
@ -35,8 +35,8 @@
|
|||
#include <boost/type_traits/is_same.hpp>
|
||||
|
||||
namespace CGAL {
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
|
||||
template<typename Triangulation, typename MeshDomain>
|
||||
|
|
@ -68,8 +68,8 @@ bool has_non_protecting_weights(const Triangulation& tr,
|
|||
}
|
||||
|
||||
|
||||
}//end namespace Mesh_3
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
} // end namespace CGAL
|
||||
|
||||
#endif //CGAL_INTERNAL_MESH_3_CHECK_WEIGHTS_H
|
||||
|
|
|
|||
|
|
@ -35,8 +35,8 @@
|
|||
#include <CGAL/IO/io.h>
|
||||
|
||||
namespace CGAL {
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
|
||||
template <typename T, typename Boost_variant>
|
||||
|
|
@ -167,8 +167,8 @@ struct Write_mesh_domain_index<Mesh_domain, false> {
|
|||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
} // end namespace CGAL
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ lloyd_optimize_mesh_3_impl(C3T3& c3t3,
|
|||
, const bool do_freeze)
|
||||
{
|
||||
CGAL_precondition(
|
||||
!internal::Mesh_3::has_non_protecting_weights(c3t3.triangulation(), domain));
|
||||
!Mesh_3::internal::has_non_protecting_weights(c3t3.triangulation(), domain));
|
||||
|
||||
typedef typename C3T3::Triangulation Tr;
|
||||
|
||||
|
|
|
|||
|
|
@ -110,7 +110,7 @@ namespace parameters {
|
|||
{
|
||||
typedef typename internal::Domain_features_generator<
|
||||
MeshDomain,
|
||||
CGAL::internal::Mesh_3::has_Has_features<MeshDomain>::value > Generator;
|
||||
CGAL::Mesh_3::internal::has_Has_features<MeshDomain>::value > Generator;
|
||||
|
||||
return Generator()();
|
||||
}
|
||||
|
|
@ -134,8 +134,8 @@ CGAL_PRAGMA_DIAG_POP
|
|||
// -----------------------------------
|
||||
// Initialize c3t3 stuff
|
||||
// -----------------------------------
|
||||
namespace internal {
|
||||
namespace Mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template < typename C3T3, typename MeshDomain, typename MeshCriteria >
|
||||
void
|
||||
|
|
@ -315,7 +315,8 @@ struct C3t3_initializer < C3T3, MD, MC, true, CGAL::Tag_false >
|
|||
}
|
||||
};
|
||||
|
||||
}} // end namespace internal::Mesh_3
|
||||
} // end namespace internal
|
||||
} // end namespace Mesh_3
|
||||
|
||||
|
||||
// -----------------------------------
|
||||
|
|
@ -456,11 +457,11 @@ void make_mesh_3_impl(C3T3& c3t3,
|
|||
#endif
|
||||
|
||||
// Initialize c3t3
|
||||
internal::Mesh_3::C3t3_initializer<
|
||||
Mesh_3::internal::C3t3_initializer<
|
||||
C3T3,
|
||||
MeshDomain,
|
||||
MeshCriteria,
|
||||
internal::Mesh_3::has_Has_features<MeshDomain>::value > () (c3t3,
|
||||
Mesh_3::internal::has_Has_features<MeshDomain>::value > () (c3t3,
|
||||
domain,
|
||||
criteria,
|
||||
with_features,
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ odt_optimize_mesh_3_impl(C3T3& c3t3,
|
|||
const bool do_freeze )
|
||||
{
|
||||
CGAL_precondition(
|
||||
!internal::Mesh_3::has_non_protecting_weights(c3t3.triangulation(), domain));
|
||||
!Mesh_3::internal::has_non_protecting_weights(c3t3.triangulation(), domain));
|
||||
|
||||
typedef typename C3T3::Triangulation Tr;
|
||||
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ perturb_mesh_3_impl(C3T3& c3t3,
|
|||
const PPerturbationVector& perturbation_vector)
|
||||
{
|
||||
CGAL_precondition(
|
||||
!internal::Mesh_3::has_non_protecting_weights(c3t3.triangulation(), domain));
|
||||
!Mesh_3::internal::has_non_protecting_weights(c3t3.triangulation(), domain));
|
||||
|
||||
typedef MeshDomain Md;
|
||||
typedef SliverCriterion Sc;
|
||||
|
|
|
|||
|
|
@ -101,7 +101,7 @@ struct Polyhedral_complex_tester : public Tester<K>
|
|||
// Mesh generation
|
||||
C3t3 c3t3;
|
||||
|
||||
CGAL::internal::Mesh_3::init_c3t3_with_features(c3t3, domain, criteria,
|
||||
CGAL::Mesh_3::internal::init_c3t3_with_features(c3t3, domain, criteria,
|
||||
true /*nonlinear_growth_of_balls*/);
|
||||
domain.add_vertices_to_c3t3_on_patch_without_feature_edges(c3t3);
|
||||
|
||||
|
|
|
|||
|
|
@ -82,15 +82,12 @@ int main(int argc, char** argv)
|
|||
// Mesh criteria
|
||||
Mesh_criteria criteria(edge_size = 0.1);
|
||||
typedef Mesh_criteria::Edge_criteria Edge_criteria;
|
||||
typedef CGAL::internal::Mesh_3::Edge_criteria_sizing_field_wrapper<Edge_criteria> Sizing_field;
|
||||
CGAL::Mesh_3::Protect_edges_sizing_field<C3t3,
|
||||
Mesh_domain,
|
||||
Sizing_field>
|
||||
protect_edges(c3t3, domain, Sizing_field(criteria.edge_criteria_object()),
|
||||
0.01);
|
||||
typedef CGAL::Mesh_3::internal::Edge_criteria_sizing_field_wrapper<Edge_criteria> Sizing_field;
|
||||
CGAL::Mesh_3::Protect_edges_sizing_field<C3t3, Mesh_domain, Sizing_field>
|
||||
protect_edges(c3t3, domain, Sizing_field(criteria.edge_criteria_object()), 0.01);
|
||||
protect_edges(true);
|
||||
|
||||
// CGAL::internal::Mesh_3::init_c3t3_with_features(c3t3, domain, criteria);
|
||||
// CGAL::Mesh_3::internal::init_c3t3_with_features(c3t3, domain, criteria);
|
||||
|
||||
// Output
|
||||
std::ofstream medit_file("out-mesh-polylines.mesh");
|
||||
|
|
|
|||
|
|
@ -37,9 +37,8 @@
|
|||
#include <iterator>
|
||||
|
||||
namespace CGAL {
|
||||
|
||||
namespace internal {
|
||||
namespace Periodic_3_mesh_3 {
|
||||
namespace internal {
|
||||
|
||||
template<typename C3T3>
|
||||
void give_dummy_points_artificial_index(C3T3& c3t3)
|
||||
|
|
@ -56,21 +55,36 @@ void give_dummy_points_artificial_index(C3T3& c3t3)
|
|||
}
|
||||
}
|
||||
|
||||
template <typename C3T3, typename MeshDomain, typename MeshCriteria>
|
||||
void init_c3t3_with_features(C3T3& c3t3,
|
||||
const MeshDomain& domain,
|
||||
const MeshCriteria& criteria,
|
||||
bool nonlinear = false)
|
||||
{
|
||||
typedef typename MeshCriteria::Edge_criteria Edge_criteria;
|
||||
typedef Mesh_3::internal::Edge_criteria_sizing_field_wrapper<Edge_criteria> Sizing_field;
|
||||
|
||||
CGAL::Periodic_3_mesh_3::Protect_edges_sizing_field<C3T3, MeshDomain, Sizing_field>
|
||||
protect_edges(c3t3, domain, Sizing_field(criteria.edge_criteria_object()));
|
||||
protect_edges.set_nonlinear_growth_of_balls(nonlinear);
|
||||
|
||||
protect_edges(true);
|
||||
}
|
||||
|
||||
// C3t3_initializer: initialize c3t3
|
||||
template < typename C3T3,
|
||||
typename MeshDomain,
|
||||
typename MeshCriteria,
|
||||
bool MeshDomainHasHasFeatures,
|
||||
typename HasFeatures = int>
|
||||
class C3t3_initializer
|
||||
: public CGAL::internal::Mesh_3::C3t3_initializer<
|
||||
struct C3t3_initializer_base
|
||||
: public CGAL::Mesh_3::internal::C3t3_initializer<
|
||||
C3T3, MeshDomain, MeshCriteria, MeshDomainHasHasFeatures, HasFeatures>
|
||||
{
|
||||
typedef CGAL::internal::Mesh_3::C3t3_initializer<
|
||||
typedef CGAL::Mesh_3::internal::C3t3_initializer<
|
||||
C3T3, MeshDomain, MeshCriteria,
|
||||
MeshDomainHasHasFeatures, HasFeatures> Base;
|
||||
|
||||
public:
|
||||
void operator()(C3T3& c3t3,
|
||||
const MeshDomain& domain,
|
||||
const MeshCriteria& criteria,
|
||||
|
|
@ -80,7 +94,6 @@ public:
|
|||
{
|
||||
c3t3.triangulation().set_domain(domain.periodic_bounding_box());
|
||||
c3t3.triangulation().insert_dummy_points();
|
||||
|
||||
give_dummy_points_artificial_index(c3t3);
|
||||
|
||||
// Call the basic initialization from c3t3, which handles features and
|
||||
|
|
@ -92,6 +105,7 @@ public:
|
|||
|
||||
} // namespace Periodic_3_mesh_3
|
||||
} // namespace internal
|
||||
} // namespace Periodic_3_mesh_3
|
||||
|
||||
// -----------------------------------
|
||||
// make_periodic_3_mesh_3 stuff
|
||||
|
|
@ -225,9 +239,9 @@ void make_periodic_3_mesh_3_impl(C3T3& c3t3,
|
|||
manifold_options = parameters::internal::Manifold_options())
|
||||
{
|
||||
// Initialize c3t3
|
||||
internal::Periodic_3_mesh_3::C3t3_initializer<
|
||||
Periodic_3_mesh_3::internal::C3t3_initializer<
|
||||
C3T3, MeshDomain, MeshCriteria,
|
||||
internal::Mesh_3::has_Has_features<MeshDomain>::value>()(c3t3,
|
||||
Mesh_3::internal::has_Has_features<MeshDomain>::value>()(c3t3,
|
||||
domain,
|
||||
criteria,
|
||||
with_features,
|
||||
|
|
|
|||
Loading…
Reference in New Issue