Changeset View
Changeset View
Standalone View
Standalone View
source/blender/modifiers/intern/MOD_weightvgproximity.c
| Show First 20 Lines • Show All 538 Lines • ▼ Show 20 Lines | if (wmd->proximity_mode == MOD_WVG_PROXIMITY_OBJECT) { | ||||
| } | } | ||||
| } | } | ||||
| else if (wmd->proximity_mode == MOD_WVG_PROXIMITY_GEOMETRY) { | else if (wmd->proximity_mode == MOD_WVG_PROXIMITY_GEOMETRY) { | ||||
| const bool use_trgt_verts = (wmd->proximity_flags & MOD_WVG_PROXIMITY_GEOM_VERTS) != 0; | const bool use_trgt_verts = (wmd->proximity_flags & MOD_WVG_PROXIMITY_GEOM_VERTS) != 0; | ||||
| const bool use_trgt_edges = (wmd->proximity_flags & MOD_WVG_PROXIMITY_GEOM_EDGES) != 0; | const bool use_trgt_edges = (wmd->proximity_flags & MOD_WVG_PROXIMITY_GEOM_EDGES) != 0; | ||||
| const bool use_trgt_faces = (wmd->proximity_flags & MOD_WVG_PROXIMITY_GEOM_FACES) != 0; | const bool use_trgt_faces = (wmd->proximity_flags & MOD_WVG_PROXIMITY_GEOM_FACES) != 0; | ||||
| if (use_trgt_verts || use_trgt_edges || use_trgt_faces) { | if (use_trgt_verts || use_trgt_edges || use_trgt_faces) { | ||||
| Mesh *target_mesh = BKE_modifier_get_evaluated_mesh_from_evaluated_object(obr, false); | Mesh *target_mesh = BKE_modifier_get_evaluated_mesh_from_evaluated_object(obr); | ||||
| /* We must check that we do have a valid target_mesh! */ | /* We must check that we do have a valid target_mesh! */ | ||||
| if (target_mesh != NULL) { | if (target_mesh != NULL) { | ||||
| /* TODO: edit-mode versions of the BVH lookup functions are available so it could be | /* TODO: edit-mode versions of the BVH lookup functions are available so it could be | ||||
| * avoided. */ | * avoided. */ | ||||
| BKE_mesh_wrapper_ensure_mdata(target_mesh); | BKE_mesh_wrapper_ensure_mdata(target_mesh); | ||||
| ▲ Show 20 Lines • Show All 216 Lines • Show Last 20 Lines | |||||