Small optimization
This commit is contained in:
parent
905673f344
commit
36252a42da
1 changed files with 9 additions and 6 deletions
|
@ -1617,12 +1617,15 @@ void GLCanvas3D::render()
|
||||||
|
|
||||||
wxGetApp().imgui()->new_frame();
|
wxGetApp().imgui()->new_frame();
|
||||||
|
|
||||||
if (m_rectangle_selection.is_dragging())
|
if (m_picking_enabled)
|
||||||
// picking pass using rectangle selection
|
{
|
||||||
_rectangular_selection_picking_pass();
|
if (m_rectangle_selection.is_dragging())
|
||||||
else
|
// picking pass using rectangle selection
|
||||||
// regular picking pass
|
_rectangular_selection_picking_pass();
|
||||||
_picking_pass();
|
else
|
||||||
|
// regular picking pass
|
||||||
|
_picking_pass();
|
||||||
|
}
|
||||||
|
|
||||||
// draw scene
|
// draw scene
|
||||||
glsafe(::glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT));
|
glsafe(::glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT));
|
||||||
|
|
Loading…
Reference in a new issue