Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenkernel/intern/mesh_fair.cc
| Show First 20 Lines • Show All 166 Lines • ▼ Show 20 Lines | for (int i = 0; i < totvert_; i++) { | ||||
| if (!affected[i]) { | if (!affected[i]) { | ||||
| continue; | continue; | ||||
| } | } | ||||
| vert_col_map.add(i, num_affected_vertices); | vert_col_map.add(i, num_affected_vertices); | ||||
| num_affected_vertices++; | num_affected_vertices++; | ||||
| } | } | ||||
| /* Early return, nothing to do. */ | /* Early return, nothing to do. */ | ||||
| if (num_affected_vertices == 0 || num_affected_vertices == totvert_) { | if (ELEM(num_affected_vertices, 0, totvert_)) { | ||||
| return; | return; | ||||
| } | } | ||||
| /* Setup fairing matrices */ | /* Setup fairing matrices */ | ||||
| LinearSolver *solver = EIG_linear_solver_new(num_affected_vertices, num_affected_vertices, 3); | LinearSolver *solver = EIG_linear_solver_new(num_affected_vertices, num_affected_vertices, 3); | ||||
| for (auto item : vert_col_map.items()) { | for (auto item : vert_col_map.items()) { | ||||
| const int v = item.key; | const int v = item.key; | ||||
| const int col = item.value; | const int col = item.value; | ||||
| ▲ Show 20 Lines • Show All 320 Lines • Show Last 20 Lines | |||||