This commit is contained in:
2018-06-09 01:40:57 +02:00
4 changed files with 16 additions and 3 deletions

View File

@@ -126,6 +126,11 @@ glm::vec4 ui::Canvas::pick_get(glm::vec2 canvas_loc)
}
return {0,0,0,1};
}
void ui::Canvas::pick_end()
{
for (int i = 0; i < 6; i++)
m_pick_data[i].release();
}
void ui::Canvas::clear(const glm::vec4& c/*={0,0,0,1}*/)
{
snap_history({ 0, 1, 2, 3, 4, 5 });
@@ -458,7 +463,9 @@ void ui::Canvas::stroke_commit()
if (!m_dirty || m_layers.empty())
return;
m_dirty = false;
m_dirty_stroke = true; // new stroke ready for timelapse capture
App::I.redraw = true;
// save viewport and clear color states
GLint vp[4];
GLfloat cc[4];