[Bf-blender-cvs] [05c64b6] fracture_modifier: dynamic fracture, fix for texture propagation and autohide on secondary fractures

Martin Felke noreply at git.blender.org
Wed Oct 5 17:29:42 CEST 2016


Commit: 05c64b674a2cb64b6006de433128cc7b361ad51e
Author: Martin Felke
Date:   Wed Oct 5 17:29:22 2016 +0200
Branches: fracture_modifier
https://developer.blender.org/rB05c64b674a2cb64b6006de433128cc7b361ad51e

dynamic fracture, fix for texture propagation and autohide on secondary fractures

===================================================================

M	source/blender/blenkernel/intern/fracture.c
M	source/blender/modifiers/intern/MOD_fracture.c

===================================================================

diff --git a/source/blender/blenkernel/intern/fracture.c b/source/blender/blenkernel/intern/fracture.c
index 604c289..3200a0a 100644
--- a/source/blender/blenkernel/intern/fracture.c
+++ b/source/blender/blenkernel/intern/fracture.c
@@ -1810,7 +1810,7 @@ static DerivedMesh* do_create(FractureModifierData *fmd, int num_verts, int num_
 			s = (Shard *)fmd->frac_mesh->shard_map.first;
 		}
 
-		if (fmd->fracture_mode == MOD_FRACTURE_PREFRACTURED)
+		if (fmd->fracture_mode == MOD_FRACTURE_PREFRACTURED || fmd->fracture_mode == MOD_FRACTURE_DYNAMIC)
 		{
 			/*keep old behavior for now for older modes */
 			CustomData_merge(&s->vertData, &result->vertData, CD_MASK_MDEFORMVERT, CD_CALLOC, num_verts);
diff --git a/source/blender/modifiers/intern/MOD_fracture.c b/source/blender/modifiers/intern/MOD_fracture.c
index 241ebb7..8b3b3e8 100644
--- a/source/blender/modifiers/intern/MOD_fracture.c
+++ b/source/blender/modifiers/intern/MOD_fracture.c
@@ -2929,7 +2929,7 @@ static void find_other_face(FractureModifierData *fmd, int i, BMesh* bm, Object*
 	int other = GET_INT_FROM_POINTER(BLI_ghash_lookup(fmd->face_pairs, SET_INT_IN_POINTER(i)));
 	int inner_index = BKE_object_material_slot_find_index(ob, fmd->inner_material) - 1;
 
-	if (other == i)
+	if ((other == i) && (fmd->fracture_mode != MOD_FRACTURE_DYNAMIC))
 	{
 		//printf("other == i %d \n", i);
 		f1 = BM_face_at_index(bm, i);




More information about the Bf-blender-cvs mailing list