mirror of https://github.com/CGAL/cgal
Address -Wunused-but-set-variable
This commit is contained in:
parent
34d8e5cd5d
commit
c352a9cd28
|
|
@ -795,8 +795,7 @@ public:
|
||||||
Assert_compile_time_tag(Supports_vertex_halfedge(), Tag_true());
|
Assert_compile_time_tag(Supports_vertex_halfedge(), Tag_true());
|
||||||
Assert_compile_time_tag(Supports_halfedge_vertex(), Tag_true());
|
Assert_compile_time_tag(Supports_halfedge_vertex(), Tag_true());
|
||||||
|
|
||||||
unsigned int nb_erased_components = 0,
|
unsigned int nb_erased_components = 0;
|
||||||
nb_isolated_vertices = 0;
|
|
||||||
|
|
||||||
// Gets list of connected components, ordered by size (i.e. number of vertices)
|
// Gets list of connected components, ordered by size (i.e. number of vertices)
|
||||||
std::vector<Vertex_handle> components;
|
std::vector<Vertex_handle> components;
|
||||||
|
|
@ -818,13 +817,9 @@ public:
|
||||||
else // if isolated vertex
|
else // if isolated vertex
|
||||||
{
|
{
|
||||||
vertices_erase(vertex);
|
vertices_erase(vertex);
|
||||||
nb_isolated_vertices++;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// if (nb_isolated_vertices > 0)
|
|
||||||
// std::cerr << " Erased " << nb_isolated_vertices << " isolated vertices\n";
|
|
||||||
|
|
||||||
return nb_erased_components;
|
return nb_erased_components;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -266,7 +266,6 @@ public:
|
||||||
|
|
||||||
// Construct the segments of the convolution cycles.
|
// Construct the segments of the convolution cycles.
|
||||||
unsigned int curr_id = 0;
|
unsigned int curr_id = 0;
|
||||||
unsigned int cycles = 0;
|
|
||||||
Segments_list conv_segments;
|
Segments_list conv_segments;
|
||||||
Segments_list cycle;
|
Segments_list cycle;
|
||||||
Labels_set used_labels;
|
Labels_set used_labels;
|
||||||
|
|
@ -340,7 +339,6 @@ public:
|
||||||
CGAL_assertion(cycle.empty());
|
CGAL_assertion(cycle.empty());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
++cycles;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
curr1 = next1;
|
curr1 = next1;
|
||||||
|
|
|
||||||
|
|
@ -485,6 +485,8 @@ check_integrity_and_topological_planarity(bool faces) const
|
||||||
std::size_t e_num = number_of_edges();
|
std::size_t e_num = number_of_edges();
|
||||||
std::size_t c_num = number_of_connected_components() - iso_vert_num;
|
std::size_t c_num = number_of_connected_components() - iso_vert_num;
|
||||||
std::size_t f_num = number_of_face_cycles() - c_num + 1;
|
std::size_t f_num = number_of_face_cycles() - c_num + 1;
|
||||||
|
CGAL_USE(fc_num);
|
||||||
|
CGAL_USE(iv_num);
|
||||||
CGAL_USE(v_num);
|
CGAL_USE(v_num);
|
||||||
CGAL_USE(e_num);
|
CGAL_USE(e_num);
|
||||||
CGAL_USE(f_num);
|
CGAL_USE(f_num);
|
||||||
|
|
|
||||||
|
|
@ -17,6 +17,7 @@
|
||||||
|
|
||||||
#include <CGAL/basic.h>
|
#include <CGAL/basic.h>
|
||||||
#include <CGAL/Unique_hash_map.h>
|
#include <CGAL/Unique_hash_map.h>
|
||||||
|
#include <CGAL/use.h>
|
||||||
#include <CGAL/Nef_2/Constrained_triang_traits.h>
|
#include <CGAL/Nef_2/Constrained_triang_traits.h>
|
||||||
#include <CGAL/Nef_2/Object_handle.h>
|
#include <CGAL/Nef_2/Object_handle.h>
|
||||||
#include <CGAL/Circulator_project.h>
|
#include <CGAL/Circulator_project.h>
|
||||||
|
|
@ -665,6 +666,7 @@ protected:
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
CGAL_USE(flip_count);
|
||||||
CGAL_NEF_TRACEN(" flipped "<<flip_count);
|
CGAL_NEF_TRACEN(" flipped "<<flip_count);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -358,6 +358,8 @@ check_integrity_and_topological_planarity(bool faces) const
|
||||||
iso_vert_num
|
iso_vert_num
|
||||||
+ number_of_sloops());
|
+ number_of_sloops());
|
||||||
CGAL_assertion_code(std::size_t f_num = number_of_sface_cycles() - c_num + 1);
|
CGAL_assertion_code(std::size_t f_num = number_of_sface_cycles() - c_num + 1);
|
||||||
|
CGAL_USE(fc_num);
|
||||||
|
CGAL_USE(iv_num);
|
||||||
CGAL_assertion_code(CGAL_NEF_TRACEV(fc_num));
|
CGAL_assertion_code(CGAL_NEF_TRACEV(fc_num));
|
||||||
CGAL_assertion_code(CGAL_NEF_TRACEV(iv_num));
|
CGAL_assertion_code(CGAL_NEF_TRACEV(iv_num));
|
||||||
CGAL_assertion_code(CGAL_NEF_TRACEV(iso_vert_num));
|
CGAL_assertion_code(CGAL_NEF_TRACEV(iso_vert_num));
|
||||||
|
|
|
||||||
|
|
@ -2180,12 +2180,10 @@ Gt, Tds >::insert_first(const Point& p)
|
||||||
CGAL_triangulation_assertion(_too_long_edge_counter == 0);
|
CGAL_triangulation_assertion(_too_long_edge_counter == 0);
|
||||||
|
|
||||||
// Insert all vertices as the first vertex in the _too_long_edges list
|
// Insert all vertices as the first vertex in the _too_long_edges list
|
||||||
int k = 0;
|
|
||||||
std::list<Vertex_handle> empty_list;
|
std::list<Vertex_handle> empty_list;
|
||||||
for (Vertex_iterator vit = vertices_begin(); vit != vertices_end(); ++vit)
|
for (Vertex_iterator vit = vertices_begin(); vit != vertices_end(); ++vit)
|
||||||
{
|
{
|
||||||
_too_long_edges[vit] = empty_list;
|
_too_long_edges[vit] = empty_list;
|
||||||
k++;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Insert all edges as all edges are too long
|
// Insert all edges as all edges are too long
|
||||||
|
|
@ -3466,11 +3464,9 @@ void Periodic_2_triangulation_2<Gt, Tds>::convert_to_9_sheeted_covering()
|
||||||
_cover = make_array(3, 3);
|
_cover = make_array(3, 3);
|
||||||
|
|
||||||
// Set up too long edges data structure
|
// Set up too long edges data structure
|
||||||
int i = 0;
|
|
||||||
for (Vertex_iterator vit = vertices_begin(); vit != vertices_end(); ++vit)
|
for (Vertex_iterator vit = vertices_begin(); vit != vertices_end(); ++vit)
|
||||||
{
|
{
|
||||||
_too_long_edges[vit] = std::list<Vertex_handle>();
|
_too_long_edges[vit] = std::list<Vertex_handle>();
|
||||||
++i;
|
|
||||||
}
|
}
|
||||||
_too_long_edge_counter = find_too_long_edges(_too_long_edges);
|
_too_long_edge_counter = find_too_long_edges(_too_long_edges);
|
||||||
|
|
||||||
|
|
@ -4434,12 +4430,10 @@ Periodic_2_triangulation_2<Gt, Tds>::load(std::istream& is)
|
||||||
for (std::size_t j = 0 ; j < m; j++)
|
for (std::size_t j = 0 ; j < m; j++)
|
||||||
is >> *(F[j]);
|
is >> *(F[j]);
|
||||||
|
|
||||||
int i = 0;
|
|
||||||
for (Vertex_iterator vi = vertices_begin();
|
for (Vertex_iterator vi = vertices_begin();
|
||||||
vi != vertices_end(); ++vi)
|
vi != vertices_end(); ++vi)
|
||||||
{
|
{
|
||||||
_too_long_edges[vi] = std::list<Vertex_handle>();
|
_too_long_edges[vi] = std::list<Vertex_handle>();
|
||||||
++i;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
_edge_length_threshold = FT(0.166) * (_domain.xmax() - _domain.xmin())
|
_edge_length_threshold = FT(0.166) * (_domain.xmax() - _domain.xmin())
|
||||||
|
|
|
||||||
|
|
@ -165,15 +165,11 @@ public:
|
||||||
spatial_sort(points.begin(), points.end(), geom_traits());
|
spatial_sort(points.begin(), points.end(), geom_traits());
|
||||||
|
|
||||||
Face_handle f;
|
Face_handle f;
|
||||||
int cnt = 0;
|
|
||||||
int cnt_good = 0;
|
|
||||||
for(typename std::vector<Point>::const_iterator p=points.begin(), end = points.end(); p != end; ++p)
|
for(typename std::vector<Point>::const_iterator p=points.begin(), end = points.end(); p != end; ++p)
|
||||||
{
|
{
|
||||||
++cnt;
|
|
||||||
Vertex_handle v = insert(*p, f);
|
Vertex_handle v = insert(*p, f);
|
||||||
if(v != Vertex_handle())
|
if(v != Vertex_handle())
|
||||||
{
|
{
|
||||||
++cnt_good;
|
|
||||||
f = v->face();
|
f = v->face();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -596,8 +592,6 @@ remove(Vertex_handle v)
|
||||||
|
|
||||||
Nbr_history failsafe;
|
Nbr_history failsafe;
|
||||||
|
|
||||||
int internb = 0;
|
|
||||||
int bdrynb = 0;
|
|
||||||
for(std::size_t i=0; i<new_f.size(); ++i)
|
for(std::size_t i=0; i<new_f.size(); ++i)
|
||||||
{
|
{
|
||||||
for(int k=0; k< 3; k++)
|
for(int k=0; k< 3; k++)
|
||||||
|
|
@ -623,7 +617,6 @@ remove(Vertex_handle v)
|
||||||
failsafe.push_back(hist);
|
failsafe.push_back(hist);
|
||||||
|
|
||||||
tds().set_adjacency(nbf, nbidx, new_f[i], k);
|
tds().set_adjacency(nbf, nbidx, new_f[i], k);
|
||||||
bdrynb++;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -641,7 +634,6 @@ remove(Vertex_handle v)
|
||||||
new_f[i]->vertex(cw(k)) == new_f[l]->vertex(ccw(j)))
|
new_f[i]->vertex(cw(k)) == new_f[l]->vertex(ccw(j)))
|
||||||
{
|
{
|
||||||
tds().set_adjacency(new_f[i], k, new_f[l], j);
|
tds().set_adjacency(new_f[i], k, new_f[l], j);
|
||||||
internb++;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -107,15 +107,17 @@ namespace CGAL {
|
||||||
{
|
{
|
||||||
#ifdef CGAL_SURFACE_MESHER_VERBOSE
|
#ifdef CGAL_SURFACE_MESHER_VERBOSE
|
||||||
std::cerr << "scanning vertices" << std::endl;
|
std::cerr << "scanning vertices" << std::endl;
|
||||||
#endif
|
|
||||||
int n = 0;
|
int n = 0;
|
||||||
|
#endif
|
||||||
for (Finite_vertices_iterator vit = SMMBB::tr.finite_vertices_begin();
|
for (Finite_vertices_iterator vit = SMMBB::tr.finite_vertices_begin();
|
||||||
vit != SMMBB::tr.finite_vertices_end();
|
vit != SMMBB::tr.finite_vertices_end();
|
||||||
++vit) {
|
++vit) {
|
||||||
if ( (SMMBB::c2t3.face_status(vit) // @TODO: appeler is_regular
|
if ( (SMMBB::c2t3.face_status(vit) // @TODO: appeler is_regular
|
||||||
== C2t3::SINGULAR) ) {
|
== C2t3::SINGULAR) ) {
|
||||||
bad_vertices.insert( vit );
|
bad_vertices.insert( vit );
|
||||||
|
#ifdef CGAL_SURFACE_MESHER_VERBOSE
|
||||||
++n;
|
++n;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
bad_vertices_initialized = true;
|
bad_vertices_initialized = true;
|
||||||
|
|
|
||||||
|
|
@ -213,8 +213,8 @@ namespace CGAL {
|
||||||
if(withBoundary)
|
if(withBoundary)
|
||||||
std::cerr << "(boundaries allowed)";
|
std::cerr << "(boundaries allowed)";
|
||||||
std::cerr << "...\n";
|
std::cerr << "...\n";
|
||||||
#endif
|
|
||||||
int n = 0;
|
int n = 0;
|
||||||
|
#endif
|
||||||
for (Finite_edges_iterator eit = SMB::tr.finite_edges_begin(); eit !=
|
for (Finite_edges_iterator eit = SMB::tr.finite_edges_begin(); eit !=
|
||||||
SMB::tr.finite_edges_end(); ++eit) {
|
SMB::tr.finite_edges_end(); ++eit) {
|
||||||
if ( (SMB::c2t3.face_status(*eit)
|
if ( (SMB::c2t3.face_status(*eit)
|
||||||
|
|
@ -223,7 +223,9 @@ namespace CGAL {
|
||||||
(SMB::c2t3.face_status(*eit)
|
(SMB::c2t3.face_status(*eit)
|
||||||
== C2t3::BOUNDARY) ) ) {
|
== C2t3::BOUNDARY) ) ) {
|
||||||
bad_edges.insert( edge_to_edgevv(*eit) );
|
bad_edges.insert( edge_to_edgevv(*eit) );
|
||||||
|
#ifdef CGAL_SURFACE_MESHER_VERBOSE
|
||||||
++n;
|
++n;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
bad_edges_initialized = true;
|
bad_edges_initialized = true;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue