diff options
author | Nicholas Bishop <nicholasbishop@gmail.com> | 2008-07-20 20:21:21 +0400 |
---|---|---|
committer | Nicholas Bishop <nicholasbishop@gmail.com> | 2008-07-20 20:21:21 +0400 |
commit | e84f5bdecf80a7981e4d830391631b8b59582f16 (patch) | |
tree | 4e57db557fd08a86b743007f3595e1937ff36762 /source/blender/src | |
parent | 431e8ff537e3e0e4159bda6c03ebea51fffd9d1a (diff) |
Fixed applying the multires modifier.
Diffstat (limited to 'source/blender/src')
-rw-r--r-- | source/blender/src/buttons_editing.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/source/blender/src/buttons_editing.c b/source/blender/src/buttons_editing.c index f5b5af779bd..38170182276 100644 --- a/source/blender/src/buttons_editing.c +++ b/source/blender/src/buttons_editing.c @@ -1356,16 +1356,16 @@ static void modifiers_applyModifier(void *obv, void *mdv) } if (ob->type==OB_MESH) { - if(me->mr && multires_modifier_warning()) { - error("Modifier changes topology; cannot apply with multires active"); - return; - } if(me->key) { error("Modifier cannot be applied to Mesh with Shape Keys"); return; } mesh_pmv_off(ob, me); + + /* Multires: ensure that recent sculpting is applied */ + if(md->type == eModifierType_Multires) + multires_force_update(ob); dm = mesh_create_derived_for_modifier(ob, md); if (!dm) { @@ -1373,6 +1373,10 @@ static void modifiers_applyModifier(void *obv, void *mdv) return; } + /* Multires: remove MDisps from the DerivedMesh */ + if(md->type == eModifierType_Multires) + CustomData_free_layers(&dm->faceData, CD_MDISPS, MultiresDM_get_totorfa(dm)); + DM_to_mesh(dm, me); converted = 1; |