3D rotate gizmo colored by axis in preview mode

This commit is contained in:
Enrico Turri 2018-08-21 09:03:38 +02:00
parent 743eee8b6e
commit edf03e00dd
2 changed files with 5 additions and 5 deletions

View file

@ -260,11 +260,11 @@ void GLGizmoRotate::on_render(const BoundingBoxf3& box) const
::glPushMatrix(); ::glPushMatrix();
transform_to_local(); transform_to_local();
::glLineWidth(2.0f);
#if ENABLE_GIZMOS_3D #if ENABLE_GIZMOS_3D
::glColor3fv((m_hover_id != -1) ? m_drag_color : m_base_color); ::glLineWidth((m_hover_id != -1) ? 2.0f : 1.5f);
::glColor3fv((m_hover_id != -1) ? m_drag_color : m_highlight_color);
#else #else
::glLineWidth(2.0f);
::glColor3fv(m_drag_color); ::glColor3fv(m_drag_color);
#endif // ENABLE_GIZMOS_3D #endif // ENABLE_GIZMOS_3D
@ -403,7 +403,7 @@ void GLGizmoRotate::render_grabber() const
m_grabbers[0].angle_z = m_angle; m_grabbers[0].angle_z = m_angle;
#if ENABLE_GIZMOS_3D #if ENABLE_GIZMOS_3D
::glColor3fv((m_hover_id != -1) ? m_drag_color : m_base_color); ::glColor3fv((m_hover_id != -1) ? m_drag_color : m_highlight_color);
#else #else
::glColor3fv(m_drag_color); ::glColor3fv(m_drag_color);
#endif // ENABLE_GIZMOS_3D #endif // ENABLE_GIZMOS_3D

View file

@ -7,7 +7,7 @@
#include <vector> #include <vector>
#define ENABLE_GIZMOS_3D 0 #define ENABLE_GIZMOS_3D 1
namespace Slic3r { namespace Slic3r {