X-Git-Url: https://eleni.mutantstargoat.com/git/?p=demo;a=blobdiff_plain;f=src%2Fopengl%2Fmesh-gl.cc;fp=src%2Fopengl%2Fmesh-gl.cc;h=531ac7888181513e6d7ff348ff4cf976590df53e;hp=6175aae985586d626c5ae4c5c5893879332a53fc;hb=d90ed8aef9e3547eee75ad793c352ee022d35050;hpb=855c42d8e50fff743fd7b1be5e91cb0db18def77 diff --git a/src/opengl/mesh-gl.cc b/src/opengl/mesh-gl.cc index 6175aae..531ac78 100644 --- a/src/opengl/mesh-gl.cc +++ b/src/opengl/mesh-gl.cc @@ -69,6 +69,8 @@ MeshGL::~MeshGL() vertices.clear(); normals.clear(); + tex_coords.clear(); + indices.clear(); } void MeshGL::draw() const @@ -115,9 +117,10 @@ void MeshGL::draw_normals(float scale) const glBindVertexArray(0); } -void MeshGL::update_vertex_data() +bool MeshGL::update_vertex_data() { update_vbo(); + return true; } void MeshGL::update_vbo() @@ -211,4 +214,4 @@ void MeshGL::destroy_vbo() glDeleteBuffers(1, &nvbo); if(nvao) glDeleteVertexArrays(1, &nvao); -} \ No newline at end of file +}