Merge from trunk
[blender.git] / source / blender / blenkernel / intern / modifier.c
index 194ce65cd86cddc37070b41cf1126254a5519767..19b7ed194ebef823c887b29ed0dff4883c50a68d 100644 (file)
@@ -1507,7 +1507,8 @@ static DerivedMesh *mirrorModifier_applyModifier(
 
        result = mirrorModifier__doMirror(mmd, ob, derivedData, 0);
 
-       CDDM_calc_normals(result);
+       if(result != derivedData)
+               CDDM_calc_normals(result);
        
        return result;
 }
@@ -5515,6 +5516,7 @@ static void particleSystemModifier_deformVerts(
        DerivedMesh *dm = derivedData;
        ParticleSystemModifierData *psmd= (ParticleSystemModifierData*) md;
        ParticleSystem * psys=0;
+       Mesh *me;
        int needsFree=0;
 
        if(ob->particlesystem.first)
@@ -5522,6 +5524,14 @@ static void particleSystemModifier_deformVerts(
        else
                return;
        
+       /* multires check */
+       if(ob->type == OB_MESH) {
+               me= (Mesh*)ob->data;
+               if(me->mr && me->mr->current != 1)
+                       modifier_setError(md,
+                               "Particles only supported on first multires level.");
+       }
+
        if(!psys_check_enabled(ob, psys))
                return;