convert to mesh (Alt+C), was failing in cases when MDef was used. make the mesh from the original rather then the copy.

This commit is contained in:
Campbell Barton
2010-03-02 15:33:33 +00:00
parent aec7174a42
commit cb22649e0b

View File

@@ -1261,7 +1261,10 @@ static int convert_exec(bContext *C, wmOperator *op)
ob1->data= copy_mesh(me);
/* make new mesh data from the original copy */
dm= mesh_get_derived_final(scene, ob1, CD_MASK_MESH);
/* note: get the mesh from the original, not from the copy in some
* cases this doesnt give correct results (when MDEF is used for eg)
*/
dm= mesh_get_derived_final(scene, ob, CD_MASK_MESH);
/* dm= mesh_create_derived_no_deform(ob1, NULL); this was called original (instead of get_derived). man o man why! (ton) */
DM_to_mesh(dm, ob1->data);