Booleans:
authorDaniel Genrich <daniel.genrich@gmx.net>
Sun, 19 Apr 2009 18:18:52 +0000 (18:18 +0000)
committerDaniel Genrich <daniel.genrich@gmx.net>
Sun, 19 Apr 2009 18:18:52 +0000 (18:18 +0000)
- Enable e.g. subsurf before boolean modifier
- Fix editmode crash

source/blender/blenkernel/intern/modifier.c

index 65bbbdfbcfbf56b2c129a5605be1de094a4d05f7..7977e7b0160046d24aa3c4d5250b808f3622d306 100644 (file)
@@ -6143,7 +6143,7 @@ static DerivedMesh *booleanModifier_applyModifier(
        DerivedMesh *dm = mesh_get_derived_final(bmd->object, CD_MASK_BAREMESH);
 
        /* we do a quick sanity check */
-       if(derivedData->getNumFaces(derivedData) > 3
+       if(dm && (derivedData->getNumFaces(derivedData) > 3)
                    && bmd->object && dm->getNumFaces(dm) > 3) {
                DerivedMesh *result = NewBooleanDerivedMesh(dm, bmd->object, derivedData, ob,
                                1 + bmd->operation);
@@ -8326,7 +8326,6 @@ ModifierTypeInfo *modifierType_getInfo(ModifierType type)
                mti = INIT_TYPE(Boolean);
                mti->type = eModifierTypeType_Nonconstructive;
                mti->flags = eModifierTypeFlag_AcceptsMesh
-                               | eModifierTypeFlag_RequiresOriginalData
                                | eModifierTypeFlag_UsesPointCache;
                mti->copyData = booleanModifier_copyData;
                mti->isDisabled = booleanModifier_isDisabled;