summaryrefslogtreecommitdiff
path: root/src/Alpha_complex/example/Alpha_complex_from_off.cpp
diff options
context:
space:
mode:
authorvrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2015-08-24 11:48:20 +0000
committervrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2015-08-24 11:48:20 +0000
commit12814e8ef128d4d19d633ce2b6931d4599ce15ba (patch)
tree0e852a9e50fad5412eb043fe48b5e4ed13e7d63a /src/Alpha_complex/example/Alpha_complex_from_off.cpp
parent2ca2d175f0b49ff267d9a99e5a4c0a5f03e0d30c (diff)
parent56f297d7338abf37ed788cace18e883d3dde1e7f (diff)
Merge trunk + alpha complex fixes
git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/alphashapes@753 636b058d-ea47-450e-bf9e-a15bfbe3eedb Former-commit-id: a0a1f71420736a0a702e6dbc76bc010b36bf5e13
Diffstat (limited to 'src/Alpha_complex/example/Alpha_complex_from_off.cpp')
-rw-r--r--src/Alpha_complex/example/Alpha_complex_from_off.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/Alpha_complex/example/Alpha_complex_from_off.cpp b/src/Alpha_complex/example/Alpha_complex_from_off.cpp
index 3ce4c7f4..b698d6d7 100644
--- a/src/Alpha_complex/example/Alpha_complex_from_off.cpp
+++ b/src/Alpha_complex/example/Alpha_complex_from_off.cpp
@@ -10,7 +10,7 @@
void usage(char * const progName) {
std::cerr << "Usage: " << progName << " filename.off alpha_square_max_value" << std::endl;
std::cerr << " i.e.: " << progName << " ../../data/points/alphacomplexdoc.off 60.0" << std::endl;
- exit(-1); // ----- >>
+ exit(-1); // ----- >>
}
int main(int argc, char **argv) {
@@ -37,12 +37,14 @@ int main(int argc, char **argv) {
std::cout << "Iterator on alpha complex simplices in the filtration order, with [filtration value]:" << std::endl;
for (auto f_simplex : alpha_complex_from_file.filtration_simplex_range()) {
- std::cout << " ( ";
- for (auto vertex : alpha_complex_from_file.simplex_vertex_range(f_simplex)) {
- std::cout << vertex << " ";
+ if (alpha_complex_from_file.filtration(f_simplex) <= alpha_complex_from_file.filtration()) {
+ std::cout << " ( ";
+ for (auto vertex : alpha_complex_from_file.simplex_vertex_range(f_simplex)) {
+ std::cout << vertex << " ";
+ }
+ std::cout << ") -> " << "[" << alpha_complex_from_file.filtration(f_simplex) << "] ";
+ std::cout << std::endl;
}
- std::cout << ") -> " << "[" << alpha_complex_from_file.filtration(f_simplex) << "] ";
- std::cout << std::endl;
}
return 0;
}