Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/sculpt_paint/sculpt_expand.c
| Show First 20 Lines • Show All 992 Lines • ▼ Show 20 Lines | |||||
| } | } | ||||
| if (new_mask == initial_mask) { | if (new_mask == initial_mask) { | ||||
| continue; | continue; | ||||
| } | } | ||||
| *vd.mask = clamp_f(new_mask, 0.0f, 1.0f); | *vd.mask = clamp_f(new_mask, 0.0f, 1.0f); | ||||
| any_changed = true; | any_changed = true; | ||||
| if (vd.mvert) { | |||||
| BKE_pbvh_vert_mark_update(ss->pbvh, vd.vertex); | |||||
| } | |||||
| } | } | ||||
| BKE_pbvh_vertex_iter_end; | BKE_pbvh_vertex_iter_end; | ||||
| if (any_changed) { | if (any_changed) { | ||||
| BKE_pbvh_node_mark_update_mask(node); | BKE_pbvh_node_mark_update_mask(node); | ||||
| } | } | ||||
| } | } | ||||
| /** | /** | ||||
| ▲ Show 20 Lines • Show All 62 Lines • ▼ Show 20 Lines | |||||
| if (equals_v4v4(initial_color, final_color)) { | if (equals_v4v4(initial_color, final_color)) { | ||||
| continue; | continue; | ||||
| } | } | ||||
| SCULPT_vertex_color_set(ss, vd.vertex, final_color); | SCULPT_vertex_color_set(ss, vd.vertex, final_color); | ||||
| any_changed = true; | any_changed = true; | ||||
| if (vd.mvert) { | |||||
| BKE_pbvh_vert_mark_update(ss->pbvh, vd.vertex); | |||||
| } | |||||
| } | } | ||||
| BKE_pbvh_vertex_iter_end; | BKE_pbvh_vertex_iter_end; | ||||
| if (any_changed) { | if (any_changed) { | ||||
| BKE_pbvh_node_mark_update_color(node); | BKE_pbvh_node_mark_update_color(node); | ||||
| } | } | ||||
| } | } | ||||
| static void sculpt_expand_flush_updates(bContext *C) | static void sculpt_expand_flush_updates(bContext *C) | ||||
| ▲ Show 20 Lines • Show All 962 Lines • Show Last 20 Lines | |||||