Subversion Repositories gelsvn

Rev

Rev 649 | Rev 656 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 649 Rev 650
Line 25... Line 25...
25
        Console::variable<int> active;
25
        Console::variable<int> active;
26
        Console::variable<std::string> display_render_mode;
26
        Console::variable<std::string> display_render_mode;
27
        Console::variable<int> display_smooth_shading;
27
        Console::variable<int> display_smooth_shading;
28
        Console::variable<float> display_gamma;
28
        Console::variable<float> display_gamma;
29
 
29
 
-
 
30
        VisObj& active_visobj() { return vo[active]; }
-
 
31
        const VisObj& active_visobj() const { return vo[active]; }
-
 
32
        
30
        GLViewController& active_view_control();
33
        GLViewController& active_view_control() {
31
        VisObj& active_visobj();
34
            return active_visobj().view_control();
-
 
35
        }
32
 
36
 
33
 
37
 
34
    public:
38
    public:
35
        MeshEditor():active(0), display_render_mode("normal"), display_smooth_shading(true),
39
        MeshEditor():active(0), display_render_mode("normal"), display_smooth_shading(true),
36
        display_gamma(2.2) {}
40
        display_gamma(2.2) {}
Line 54... Line 58...
54
        
58
        
55
        /// Make sure the object fits in the window.
59
        /// Make sure the object fits in the window.
56
        void refit() {
60
        void refit() {
57
            active_visobj().refit();
61
            active_visobj().refit();
58
        }
62
        }
-
 
63
        
-
 
64
        /// Returns the name of the file whence the active mesh was loaded.
-
 
65
        const std::string& file_name() const {return active_visobj().file_name();}
59
 
66
 
60
        // Get mesh and mesh state.
67
        // Get mesh and mesh state.
61
        HMesh::Manifold& active_mesh();
-
 
62
        void save_active_mesh() {active_visobj().save_old();}
68
        void save_active_mesh() {active_visobj().save_old();}
63
        void restore_active_mesh() {active_visobj().restore_old();}
69
        void restore_active_mesh() {active_visobj().restore_old();}
64
 
70
 
65
        // Display functions ------------
71
        // Display functions ------------
66
        
72
        
Line 83... Line 89...
83
        void key_down();
89
        void key_down();
84
        void key_left();
90
        void key_left();
85
        void key_right();
91
        void key_right();
86
        void key_home();
92
        void key_home();
87
        void key_end();
93
        void key_end();
-
 
94
 
-
 
95
        /// Returns a reference to active mesh.
-
 
96
        HMesh::Manifold& active_mesh() { return active_visobj().mesh(); }
88
        
97
        
89
        
-
 
90
        /// Add a file to the next empty slot.
98
       /// Add a file to the next empty slot.
91
        bool add_file(const std::string& str);
99
        bool add_file(const std::string& str);
92
        
100
        
93
        /// Load the mesh given as argument to the current slot.
101
        /// Load the mesh given as argument to the current slot.
94
        bool reload_active_from_file(const std::string& str);
102
        bool reload_active_from_file(const std::string& str);
95
        
103