Commit dcaf154b by Philipp Adolf

Add sharp_edges to Input

parent 89c9bfac
......@@ -81,6 +81,7 @@ void Subdivision::subdivide(Mesh *mesh, int level) {
input.vb_handle = entry->VB_handle;
input.vertex_buffer = entry->vertices;
input.index_irregular_buffer = entry->indices_irregular;
input.sharp_edges = entry->m_sharp_edges;
input.index_regular_buffer = patchIBToTriangleIB(entry->indices_regular);
if (input.index_irregular_buffer.isEmpty()) {
......@@ -119,8 +120,7 @@ void Subdivision::subdivide(Mesh *mesh, int level) {
getPatchIndexBuffer(regular, neighbors, patches);
qCDebug(log_subdiv) << "patches" << patches.length();
QMap<Edge, unsigned int> sharpEdges;
current_mesh->update(result.vb_handle, result.vertex_buffer, result.vertex_buffer_irregular, irregular_ib, sharpEdges, patches,tables.extra_triangles);
current_mesh->update(result.vb_handle, result.vertex_buffer, result.vertex_buffer_irregular, irregular_ib, input.sharp_edges, patches, tables.extra_triangles);
qCDebug(log_timing) << "subdivide done:" << formatTimeMeasurement(timer.elapsed());
}
......
......@@ -24,6 +24,7 @@ private:
GLuint vb_handle;
QVector<unsigned int> index_irregular_buffer;
QVector<unsigned int> index_regular_buffer;
QMap<Edge,unsigned int> sharp_edges;
QVector<Vertex> vertex_buffer;
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment