Tech ENABLE_GLBEGIN_GLEND_REMOVAL - Selection layers hints

(cherry picked from commit prusa3d/PrusaSlicer@bebb5505a3)
This commit is contained in:
enricoturri1966 2023-10-20 20:51:00 +08:00 committed by Noisyfox
parent 7f0c095446
commit 356405adf6
4 changed files with 108 additions and 57 deletions

View file

@ -221,6 +221,12 @@ private:
GLModel m_arrow;
GLModel m_curved_arrow;
GLModel m_box;
struct Planes
{
std::array<Vec3f, 2> check_points{ Vec3f::Zero(), Vec3f::Zero() };
std::array<GLModel, 2> models;
};
Planes m_planes;
float m_scale_factor;
bool m_dragging;
@ -355,11 +361,11 @@ public:
void erase();
void render(float scale_factor = 1.0);
//BBS: GUI refactor: add uniform scale from gizmo
void render_sidebar_hints(const std::string& sidebar_field, bool uniform_scale);
#if ENABLE_RENDER_SELECTION_CENTER
void render_center(bool gizmo_is_dragging);
#endif // ENABLE_RENDER_SELECTION_CENTER
//BBS: GUI refactor: add uniform scale from gizmo
void render_sidebar_hints(const std::string& sidebar_field, bool uniform_scale) const;
bool requires_local_axes() const;
@ -402,11 +408,11 @@ private:
void set_bounding_boxes_dirty() { m_bounding_box.reset(); m_unscaled_instance_bounding_box.reset(); m_scaled_instance_bounding_box.reset(); }
void render_synchronized_volumes();
void render_bounding_box(const BoundingBoxf3& box, const ColorRGB& color);
void render_sidebar_position_hints(const std::string& sidebar_field) const;
void render_sidebar_rotation_hints(const std::string& sidebar_field) const;
void render_sidebar_position_hints(const std::string& sidebar_field);
void render_sidebar_rotation_hints(const std::string& sidebar_field);
//BBS: GUI refactor: add uniform_scale from gizmo
void render_sidebar_scale_hints(const std::string& sidebar_field, bool gizmo_uniform_scale) const;
void render_sidebar_layers_hints(const std::string& sidebar_field) const;
void render_sidebar_scale_hints(const std::string& sidebar_field, bool gizmo_uniform_scale);
void render_sidebar_layers_hints(const std::string& sidebar_field);
public:
enum SyncRotationType {