mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-20 11:53:48 +00:00
Visual hints in the 3D scene when sidebar matrix fields have focus -> legacy render case
This commit is contained in:
@@ -1920,8 +1920,7 @@ void GLModel::render() const
|
|||||||
if (m_useVBOs)
|
if (m_useVBOs)
|
||||||
render_VBOs();
|
render_VBOs();
|
||||||
else
|
else
|
||||||
{
|
render_legacy();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void GLModel::render_VBOs() const
|
void GLModel::render_VBOs() const
|
||||||
@@ -1949,6 +1948,25 @@ void GLModel::render_VBOs() const
|
|||||||
::glDisable(GL_BLEND);
|
::glDisable(GL_BLEND);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GLModel::render_legacy() const
|
||||||
|
{
|
||||||
|
::glEnable(GL_LIGHTING);
|
||||||
|
::glEnable(GL_BLEND);
|
||||||
|
::glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
|
||||||
|
|
||||||
|
::glCullFace(GL_BACK);
|
||||||
|
::glEnableClientState(GL_VERTEX_ARRAY);
|
||||||
|
::glEnableClientState(GL_NORMAL_ARRAY);
|
||||||
|
|
||||||
|
m_volume.render_legacy();
|
||||||
|
|
||||||
|
::glDisableClientState(GL_VERTEX_ARRAY);
|
||||||
|
::glDisableClientState(GL_NORMAL_ARRAY);
|
||||||
|
|
||||||
|
::glDisable(GL_BLEND);
|
||||||
|
::glDisable(GL_LIGHTING);
|
||||||
|
}
|
||||||
|
|
||||||
bool GLArrow::on_init(bool useVBOs)
|
bool GLArrow::on_init(bool useVBOs)
|
||||||
{
|
{
|
||||||
Pointf3s vertices;
|
Pointf3s vertices;
|
||||||
|
|||||||
@@ -611,6 +611,7 @@ protected:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
void render_VBOs() const;
|
void render_VBOs() const;
|
||||||
|
void render_legacy() const;
|
||||||
};
|
};
|
||||||
|
|
||||||
class GLArrow : public GLModel
|
class GLArrow : public GLModel
|
||||||
|
|||||||
Reference in New Issue
Block a user