render task queue the color pick action

This commit is contained in:
2019-07-28 12:11:23 +02:00
parent 36be53aba5
commit 37331d4e24

View File

@@ -72,6 +72,8 @@ void Canvas::pick_update(int plane)
if (m_pick_ready[plane])
return;
App::I->render_task([this, plane]
{
// save viewport and clear color states
GLint vp[4];
GLfloat cc[4];
@@ -114,7 +116,7 @@ void Canvas::pick_update(int plane)
glViewport(vp[0], vp[1], vp[2], vp[3]);
glClearColor(cc[0], cc[1], cc[2], cc[3]);
glActiveTexture(GL_TEXTURE0);
});
m_pick_ready[plane] = true;
}