Mesh: Remove unnecessary mesh position copying #105756
|
@ -745,6 +745,7 @@ static GeometrySet curve_calc_modifiers_post(Depsgraph *depsgraph,
|
|||
if (mti->type == eModifierTypeType_OnlyDeform) {
|
||||
mti->deformVerts(
|
||||
md, &mectx_deform, mesh, BKE_mesh_vert_positions_for_write(mesh), mesh->totvert);
|
||||
sixthat marked this conversation as resolved
|
||||
BKE_mesh_tag_positions_changed(mesh);
|
||||
}
|
||||
else {
|
||||
Mesh *output_mesh = mti->modifyMesh(md, &mectx_apply, mesh);
|
||||
|
|
|
@ -687,6 +687,7 @@ void BKE_mball_data_update(Depsgraph *depsgraph, Scene *scene, Object *ob)
|
|||
if (ob->parent && ob->parent->type == OB_LATTICE && ob->partype == PARSKEL) {
|
||||
BKE_lattice_deform_coords(
|
||||
ob->parent, ob, BKE_mesh_vert_positions_for_write(mesh), mesh->totvert, 0, nullptr, 1.0f);
|
||||
BKE_mesh_tag_positions_changed(mesh);
|
||||
}
|
||||
|
||||
ob->runtime.geometry_set_eval = new GeometrySet(GeometrySet::create_with_mesh(mesh));
|
||||
|
|
|
@ -3500,6 +3500,7 @@ static void do_hair_dynamics(ParticleSimulationData *sim)
|
|||
sim->ob,
|
||||
psys->hair_in_mesh,
|
||||
BKE_mesh_vert_positions_for_write(psys->hair_in_mesh));
|
||||
sixthat marked this conversation as resolved
Outdated
Hans Goudey
commented
The update tag from The update tag from `BKE_mesh_vert_coords_apply` is missing here too.
|
||||
BKE_mesh_tag_positions_changed(psys->hair_in_mesh);
|
||||
|
||||
/* restore cloth effector weights */
|
||||
psys->clmd->sim_parms->effector_weights = clmd_effweights;
|
||||
|
|
|
@ -1547,6 +1547,7 @@ void BKE_shrinkwrap_mesh_nearest_surface_deform(bContext *C, Object *ob_source,
|
|||
-1,
|
||||
BKE_mesh_vert_positions_for_write(src_me),
|
||||
src_me->totvert);
|
||||
sixthat marked this conversation as resolved
Hans Goudey
commented
Same here Same here
|
||||
BKE_mesh_tag_positions_changed(src_me);
|
||||
}
|
||||
|
||||
void BKE_shrinkwrap_remesh_target_project(Mesh *src_me, Mesh *target_me, Object *ob_target)
|
||||
|
|
Loading…
Reference in New Issue
This needs a call to
BKE_mesh_tag_positions_changed
, otherwise various caches that depend on mesh positions won't be properly updated after the deformation.