Group instancing usablitity issue: Hotkey SHIFT+O to set subsurf on/off
authorTon Roosendaal <ton@blender.org>
Mon, 3 Dec 2007 16:21:16 +0000 (16:21 +0000)
committerTon Roosendaal <ton@blender.org>
Mon, 3 Dec 2007 16:21:16 +0000 (16:21 +0000)
should not work if object had not a subsurf modifier before.

source/blender/src/editobject.c

index 8f3d9779a0dace71ad0ab625b95add62f4d02618..1bf3fe7ea7278bedfe3a0e4ed072b98c2b60521a 100644 (file)
@@ -2880,10 +2880,12 @@ void flip_subdivison(int level)
        for(base= G.scene->base.first; base; base= base->next) {
                if(((level==-1) && (TESTBASE(base))) || (TESTBASELIB(base))) {
                        object_flip_subdivison(base->object, &set, level, mode);
+                       
                        if(base->object->dup_group) {
                                GroupObject *go;
                                for(go= base->object->dup_group->gobject.first; go; go= go->next)
-                                       object_flip_subdivison(go->ob, &set, level, mode);
+                                       if( modifiers_findByType(go->ob, eModifierType_Subsurf))        /* only when exists */
+                                               object_flip_subdivison(go->ob, &set, level, mode);
                        }
                }
        }