MainWindow.h
1 /* This file is part of the Gudhi Library - https://gudhi.inria.fr/ - which is released under MIT.
2  * See file LICENSE or go to https://gudhi.inria.fr/licensing/ for full license details.
3  * Author(s): David Salinas
4  *
5  * Copyright (C) 2014 Inria
6  *
7  * Modification(s):
8  * - YYYY/MM Author: Description of the modification
9  */
10 
11 #ifndef GUI_MAINWINDOW_H_
12 #define GUI_MAINWINDOW_H_
13 
14 // Workaround https://svn.boost.org/trac/boost/ticket/12534
15 #include <boost/container/flat_map.hpp>
16 
17 #include <QMainWindow>
18 #include "ui_main_window.h"
19 #include "model/Model.h"
20 #include "view/Viewer_instructor.h"
21 
22 
23 class Menu_k_nearest_neighbors;
24 class Menu_uniform_neighbors;
25 class Menu_edge_contraction;
26 class Menu_persistence;
27 
28 class MainWindow : public QMainWindow, public Ui::MainWindow {
29  Q_OBJECT
30 
31  private:
32  Model model_;
33  Viewer_instructor* viewer_instructor_;
34  Menu_k_nearest_neighbors* menu_k_nearest_neighbors_;
35  Menu_uniform_neighbors* menu_uniform_neighbors_;
36  Menu_edge_contraction* menu_edge_contraction_;
37  Menu_persistence* menu_persistence_;
38 
39  public:
40  MainWindow(QWidget* parent = 0);
41  void connectActions();
42 
46  void init_view() const;
47  void update_view() const;
48 
49 
50  protected:
51  void closeEvent(QCloseEvent *event);
52 
53  void keyPressEvent(QKeyEvent *event) { }
54 
55  public:
56  public slots:
60  void off_file_open();
61 
62  void off_points_open();
63 
67  void off_file_save();
68  void off_points_save();
69 
70  void show_graph_stats();
71  void show_complex_stats();
72  void show_complex_dimension();
73 
74 
75  void build_rips_menu();
76  void build_rips(double alpha);
77  void build_k_nearest_neighbors_menu();
78  void build_k_nearest_neighbors(unsigned k);
79 
80 
81  void contract_edge_menu();
82  void contract_edges(unsigned num_collapses);
83 
84 
85  void collapse_vertices();
86  void collapse_edges();
87 
88 
89  void uniform_noise();
90  void lloyd();
91 
92  void show_homology_group();
93  void show_euler_characteristic();
94  void persistence_menu();
95  void compute_persistence(int p, double threshold, int max_dim, double min_pers);
96  void critical_points_menu();
97  void is_manifold_menu();
98 
99 
100  public:
101  signals:
102  void sceneChanged() const;
103 };
104 
105 
106 #endif // GUI_MAINWINDOW_H_
GUDHIdev  Version 3.5.0  - C++ library for Topological Data Analysis (TDA) and Higher Dimensional Geometry Understanding.  - Copyright : MIT Generated on Tue Aug 16 2022 14:01:50 for GUDHIdev by Doxygen 1.9.1