svn merge ^/trunk/blender -r44024:44076
authorCampbell Barton <ideasman42@gmail.com>
Mon, 13 Feb 2012 04:14:35 +0000 (04:14 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Mon, 13 Feb 2012 04:14:35 +0000 (04:14 +0000)
1  2 
source/blender/blenkernel/intern/particle.c
source/blender/blenkernel/intern/particle_system.c
source/blender/editors/armature/meshlaplacian.c
source/blender/editors/mesh/mesh_data.c
source/blender/editors/screen/screen_ops.c
source/blender/editors/space_outliner/outliner_edit.c
source/blender/makesrna/intern/rna_modifier.c
source/blender/modifiers/intern/MOD_explode.c

@@@ -563,10 -399,14 +563,14 @@@ static int drop_named_image_invoke(bCon
        ED_uvedit_assign_image(bmain, scene, obedit, ima, NULL);
  
        if(exitmode) {
 -              load_editMesh(scene, obedit);
 -              free_editMesh(me->edit_mesh);
 -              MEM_freeN(me->edit_mesh);
 -              me->edit_mesh= NULL;
 +              EDBM_LoadEditBMesh(scene, obedit);
 +              EDBM_FreeEditBMesh(me->edit_btmesh);
 +              MEM_freeN(me->edit_btmesh);
 +              me->edit_btmesh= NULL;
+               /* load_editMesh free's pointers used by CustomData layers which might be used by DerivedMesh too,
+                * so signal to re-create DerivedMesh here (sergey) */
+               DAG_id_tag_update(&me->id, 0);
        }
  
        /* dummie drop support; ensure view shows a result :) */
@@@ -496,7 -496,7 +496,6 @@@ static int outliner_toggle_renderabilit
  {
        SpaceOops *soops= CTX_wm_space_outliner(C);
        Scene *scene= CTX_data_scene(C);
--      ARegion *ar= CTX_wm_region(C);
        
        outliner_do_object_operation(C, scene, soops, &soops->tree, object_toggle_renderability_cb);
        
@@@ -844,7 -850,7 +856,7 @@@ static DerivedMesh * explodeMesh(Explod
        BLI_edgehashIterator_free(ehi);
  
        /* the final duplicated vertices */
-       explode= CDDM_from_template(dm, totdup, 0,totface, 0, 0);
 -      explode= CDDM_from_template(dm, totdup, 0,totface-delface);
++      explode= CDDM_from_template(dm, totdup, 0,totface-delface, 0, 0);
        mtface = CustomData_get_layer_named(&explode->faceData, CD_MTFACE, emd->uvname);
        /*dupvert= CDDM_get_verts(explode);*/
  
                        if(pa->alive==PARS_DEAD && (emd->flag&eExplodeFlag_Dead)==0) continue;
                }
  
 -              dm->getFace(dm,i,&source);
 -              mf=CDDM_get_face(explode,u);
 +              dm->getTessFace(dm,i,&source);
-               mf=CDDM_get_tessface(explode,i);
++              mf=CDDM_get_tessface(explode,u);
                
                orig_v4 = source.v4;
  
                if(source.v4)
                        source.v4 = edgecut_get(vertpahash, source.v4, mindex);
  
-               DM_copy_tessface_data(dm,explode,i,i,1);
 -              DM_copy_face_data(dm,explode,i,u,1);
++              DM_copy_tessface_data(dm,explode,i,u,1);
  
                *mf = source;