Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/sculpt_paint/paint_hide.c
| Show First 20 Lines • Show All 360 Lines • ▼ Show 20 Lines | static int hide_show_exec(bContext *C, wmOperator *op) | ||||
| get_pbvh_nodes(pbvh, &nodes, &totnode, clip_planes, area); | get_pbvh_nodes(pbvh, &nodes, &totnode, clip_planes, area); | ||||
| pbvh_type = BKE_pbvh_type(pbvh); | pbvh_type = BKE_pbvh_type(pbvh); | ||||
| negate_m4(clip_planes); | negate_m4(clip_planes); | ||||
| /* Start undo. */ | /* Start undo. */ | ||||
| switch (action) { | switch (action) { | ||||
| case PARTIALVIS_HIDE: | case PARTIALVIS_HIDE: | ||||
| SCULPT_undo_push_begin("Hide area"); | SCULPT_undo_push_begin(ob, "Hide area"); | ||||
| break; | break; | ||||
| case PARTIALVIS_SHOW: | case PARTIALVIS_SHOW: | ||||
| SCULPT_undo_push_begin("Show area"); | SCULPT_undo_push_begin(ob, "Show area"); | ||||
| break; | break; | ||||
| } | } | ||||
| for (int i = 0; i < totnode; i++) { | for (int i = 0; i < totnode; i++) { | ||||
| switch (pbvh_type) { | switch (pbvh_type) { | ||||
| case PBVH_FACES: | case PBVH_FACES: | ||||
| partialvis_update_mesh(ob, pbvh, nodes[i], action, area, clip_planes); | partialvis_update_mesh(ob, pbvh, nodes[i], action, area, clip_planes); | ||||
| break; | break; | ||||
| ▲ Show 20 Lines • Show All 86 Lines • Show Last 20 Lines | |||||