mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-10-22 08:11:11 -06:00
3DScene member variables moved to c++
This commit is contained in:
parent
2dee4d1a83
commit
e79037c44d
10 changed files with 104 additions and 16 deletions
|
@ -1857,6 +1857,21 @@ void _3DScene::set_cutting_plane(wxGLCanvas* canvas, float z, const ExPolygons&
|
|||
return s_canvas_mgr.set_cutting_plane(canvas, z, polygons);
|
||||
}
|
||||
|
||||
void _3DScene::set_color_by(wxGLCanvas* canvas, const std::string& value)
|
||||
{
|
||||
return s_canvas_mgr.set_color_by(canvas, value);
|
||||
}
|
||||
|
||||
void _3DScene::set_select_by(wxGLCanvas* canvas, const std::string& value)
|
||||
{
|
||||
return s_canvas_mgr.set_select_by(canvas, value);
|
||||
}
|
||||
|
||||
void _3DScene::set_drag_by(wxGLCanvas* canvas, const std::string& value)
|
||||
{
|
||||
return s_canvas_mgr.set_drag_by(canvas, value);
|
||||
}
|
||||
|
||||
bool _3DScene::is_layers_editing_enabled(wxGLCanvas* canvas)
|
||||
{
|
||||
return s_canvas_mgr.is_layers_editing_enabled(canvas);
|
||||
|
|
|
@ -575,6 +575,10 @@ public:
|
|||
|
||||
static void set_cutting_plane(wxGLCanvas* canvas, float z, const ExPolygons& polygons);
|
||||
|
||||
static void set_color_by(wxGLCanvas* canvas, const std::string& value);
|
||||
static void set_select_by(wxGLCanvas* canvas, const std::string& value);
|
||||
static void set_drag_by(wxGLCanvas* canvas, const std::string& value);
|
||||
|
||||
static bool is_layers_editing_enabled(wxGLCanvas* canvas);
|
||||
static bool is_layers_editing_allowed(wxGLCanvas* canvas);
|
||||
static bool is_shader_enabled(wxGLCanvas* canvas);
|
||||
|
|
|
@ -1149,6 +1149,21 @@ void GLCanvas3D::set_cutting_plane(float z, const ExPolygons& polygons)
|
|||
m_cutting_plane.set(z, polygons);
|
||||
}
|
||||
|
||||
void GLCanvas3D::set_color_by(const std::string& value)
|
||||
{
|
||||
m_color_by = value;
|
||||
}
|
||||
|
||||
void GLCanvas3D::set_select_by(const std::string& value)
|
||||
{
|
||||
m_select_by = value;
|
||||
}
|
||||
|
||||
void GLCanvas3D::set_drag_by(const std::string& value)
|
||||
{
|
||||
m_drag_by = value;
|
||||
}
|
||||
|
||||
float GLCanvas3D::get_camera_zoom() const
|
||||
{
|
||||
return m_camera.zoom;
|
||||
|
|
|
@ -386,7 +386,11 @@ public:
|
|||
void set_axes_length(float length);
|
||||
|
||||
void set_cutting_plane(float z, const ExPolygons& polygons);
|
||||
|
||||
|
||||
void set_color_by(const std::string& value);
|
||||
void set_select_by(const std::string& value);
|
||||
void set_drag_by(const std::string& value);
|
||||
|
||||
float get_camera_zoom() const;
|
||||
|
||||
BoundingBoxf3 volumes_bounding_box() const;
|
||||
|
|
|
@ -317,6 +317,27 @@ void GLCanvas3DManager::set_cutting_plane(wxGLCanvas* canvas, float z, const ExP
|
|||
it->second->set_cutting_plane(z, polygons);
|
||||
}
|
||||
|
||||
void GLCanvas3DManager::set_color_by(wxGLCanvas* canvas, const std::string& value)
|
||||
{
|
||||
CanvasesMap::iterator it = _get_canvas(canvas);
|
||||
if (it != m_canvases.end())
|
||||
it->second->set_color_by(value);
|
||||
}
|
||||
|
||||
void GLCanvas3DManager::set_select_by(wxGLCanvas* canvas, const std::string& value)
|
||||
{
|
||||
CanvasesMap::iterator it = _get_canvas(canvas);
|
||||
if (it != m_canvases.end())
|
||||
it->second->set_select_by(value);
|
||||
}
|
||||
|
||||
void GLCanvas3DManager::set_drag_by(wxGLCanvas* canvas, const std::string& value)
|
||||
{
|
||||
CanvasesMap::iterator it = _get_canvas(canvas);
|
||||
if (it != m_canvases.end())
|
||||
it->second->set_drag_by(value);
|
||||
}
|
||||
|
||||
bool GLCanvas3DManager::is_layers_editing_enabled(wxGLCanvas* canvas) const
|
||||
{
|
||||
CanvasesMap::const_iterator it = _get_canvas(canvas);
|
||||
|
|
|
@ -70,6 +70,10 @@ public:
|
|||
|
||||
void set_cutting_plane(wxGLCanvas* canvas, float z, const ExPolygons& polygons);
|
||||
|
||||
void set_color_by(wxGLCanvas* canvas, const std::string& value);
|
||||
void set_select_by(wxGLCanvas* canvas, const std::string& value);
|
||||
void set_drag_by(wxGLCanvas* canvas, const std::string& value);
|
||||
|
||||
bool is_layers_editing_enabled(wxGLCanvas* canvas) const;
|
||||
bool is_layers_editing_allowed(wxGLCanvas* canvas) const;
|
||||
bool is_shader_enabled(wxGLCanvas* canvas) const;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue