mirror of https://github.com/CGAL/cgal
Improve comments and remove useless comments
This commit is contained in:
parent
d2f6062ac1
commit
a86d84e68c
|
|
@ -27,9 +27,6 @@
|
|||
#ifndef CGAL_COMPUTE_CONE_BOUNDARIES_2_H
|
||||
#define CGAL_COMPUTE_CONE_BOUNDARIES_2_H
|
||||
|
||||
// if leda::real is used, pls modify the following definition
|
||||
//#define CGAL_USE_CORE 1
|
||||
|
||||
#include <iostream>
|
||||
#include <cstdlib>
|
||||
#include <vector>
|
||||
|
|
@ -58,7 +55,8 @@ namespace CGAL {
|
|||
* Of course, this functor can also be used in other applications where the plane needs to be divided
|
||||
* into equally-angled cones.
|
||||
*
|
||||
* \tparam Traits_ must be either `CGAL::Exact_predicates_exact_constructions_kernel_with_root_of` or `CGAL::Exact_predicates_inexact_constructions_kernel`.
|
||||
* \tparam Traits_ Must be either `CGAL::Exact_predicates_exact_constructions_kernel_with_root_of`
|
||||
* or `CGAL::Exact_predicates_inexact_constructions_kernel`.
|
||||
*
|
||||
*/
|
||||
template <typename Traits_>
|
||||
|
|
@ -76,8 +74,7 @@ private:
|
|||
typedef typename Traits::Aff_transformation_2 Transformation;
|
||||
|
||||
public:
|
||||
/* No member variables in this class, so a custom constructor is not needed. */
|
||||
// Compute_cone_boundaries_2() {};
|
||||
/* Note: No member variables in this class, so a custom constructor is not needed. */
|
||||
|
||||
/*! \brief The operator().
|
||||
*
|
||||
|
|
@ -137,8 +134,7 @@ private:
|
|||
typedef Kernel_type::Aff_transformation_2 Transformation;
|
||||
|
||||
public:
|
||||
/* No member variables in this class, so a Constructor is not needed. */
|
||||
// Compute_cone_boundaries_2() {};
|
||||
/* Note: No member variables in this class, so a Constructor is not needed. */
|
||||
|
||||
/* The operator().
|
||||
|
||||
|
|
@ -160,8 +156,6 @@ public:
|
|||
std::exit(1);
|
||||
}
|
||||
|
||||
//std::cout << "Specialization is called!" << std::endl;
|
||||
|
||||
// Since CGAL::root_of() gives the k-th smallest root,
|
||||
// here -x is actually used instead of x.
|
||||
// But we want the second largest one with no need to count.
|
||||
|
|
|
|||
|
|
@ -211,7 +211,7 @@ public:
|
|||
return res;
|
||||
}
|
||||
|
||||
/* Constant Reverse order End Iterator */
|
||||
/* Constant Reverse order End Iterator */
|
||||
const_reverse_iterator rend() const {
|
||||
static const_reverse_iterator res;
|
||||
|
||||
|
|
|
|||
|
|
@ -39,14 +39,15 @@ namespace CGAL {
|
|||
|
||||
/*! \ingroup PkgConeBasedSpanners
|
||||
|
||||
\brief A template functor for constructing Yao graphs with a given set of 2D points and
|
||||
\brief A template functor for constructing Yao graphs with a given set of 2D points and
|
||||
a given initial direction for the cone boundaries.
|
||||
|
||||
\tparam Traits_ must be either `CGAL::Exact_predicates_exact_constructions_kernel_with_root_of` or `CGAL::Exact_predicates_inexact_constructions_kernel`.
|
||||
|
||||
\tparam Graph_ is the graph type to store the constructed cone based spanner.
|
||||
It must be <A HREF="http://www.boost.org/libs/graph/doc/adjacency_list.html">`boost::adjacency_list`</A> with `Traits_::Point_2` as `VertexProperties`
|
||||
\tparam Traits_ Must be either `CGAL::Exact_predicates_exact_constructions_kernel_with_root_of`
|
||||
or `CGAL::Exact_predicates_inexact_constructions_kernel`.
|
||||
|
||||
\tparam Graph_ The graph type to store the constructed cone based spanner.
|
||||
It must be <A HREF="http://www.boost.org/libs/graph/doc/adjacency_list.html">`boost::adjacency_list`</A>
|
||||
with `Traits_::Point_2` as `VertexProperties`
|
||||
*/
|
||||
template <typename Traits_, typename Graph_>
|
||||
class Construct_yao_graph_2 {
|
||||
|
|
@ -102,12 +103,6 @@ public:
|
|||
compute_cones(k, initial_direction, rays.begin());
|
||||
}
|
||||
|
||||
/* \brief Copy constructor. Not needed.
|
||||
\param x another Construct_yao_graph_2 object to copy from.
|
||||
|
||||
Construct_yao_graph_2 (const Construct_yao_graph_2& x) : cone_number(x.cone_number), rays(x.rays) {}
|
||||
*/
|
||||
|
||||
/*!
|
||||
\brief Function operator to construct a Yao graph.
|
||||
|
||||
|
|
@ -123,7 +118,6 @@ public:
|
|||
Graph_& operator()(const PointInputIterator& start,
|
||||
const PointInputIterator& end,
|
||||
Graph_& g) {
|
||||
|
||||
// add vertices into the graph
|
||||
for (PointInputIterator curr = start; curr != end; ++curr) {
|
||||
g[boost::add_vertex(g)] = *curr;
|
||||
|
|
@ -210,8 +204,6 @@ protected:
|
|||
boost::tie(existing_e, existing)=boost::edge(*it, *min, g);
|
||||
if (!existing)
|
||||
boost::add_edge(*it, *min, g);
|
||||
//else
|
||||
// std::cout << "Edge " << *it << ", " << *min << " already exists!" << std::endl;
|
||||
}
|
||||
|
||||
} // end of for
|
||||
|
|
|
|||
|
|
@ -172,7 +172,7 @@ void gnuplot_output_2 (const Graph& g, const std::string& prefix)
|
|||
fs << "unset ytics" << std::endl;
|
||||
fs << "unset border" << std::endl;
|
||||
|
||||
/*
|
||||
/* Uncomment if you need the following:
|
||||
ss << "set xtics" << std::endl;
|
||||
ss << "set ytics" << std::endl;
|
||||
ss << "set border" << std::endl;
|
||||
|
|
|
|||
Loading…
Reference in New Issue