[Bf-blender-cvs] [d34550c] fracture_modifier: fixes: lower stability factor now lets the object break earlier ( effect was inverted) and added uv_layer to fracture presets (was missing)

Martin Felke noreply at git.blender.org
Tue Jan 5 15:55:50 CET 2016


Commit: d34550c126495f3967c12110f43a1e776a925491
Author: Martin Felke
Date:   Tue Jan 5 15:55:20 2016 +0100
Branches: fracture_modifier
https://developer.blender.org/rBd34550c126495f3967c12110f43a1e776a925491

fixes: lower stability factor now lets the object break earlier ( effect was inverted) and added uv_layer to fracture presets (was missing)

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

M	release/scripts/startup/bl_operators/presets.py
M	source/blender/modifiers/intern/MOD_fracture.c

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

diff --git a/release/scripts/startup/bl_operators/presets.py b/release/scripts/startup/bl_operators/presets.py
index b74b855..125b8d6 100644
--- a/release/scripts/startup/bl_operators/presets.py
+++ b/release/scripts/startup/bl_operators/presets.py
@@ -674,7 +674,8 @@ class AddPresetFracture(AddPresetBase, Operator):
        # "fracture.directional_factor",
         "fracture.minimum_impulse",
         "fracture.mass_threshold_factor",
-        "fracture.autohide_filter_group"
+        "fracture.autohide_filter_group",
+        "fracture.uv_layer"
     ]
 
     preset_subdir = "fracture"
diff --git a/source/blender/modifiers/intern/MOD_fracture.c b/source/blender/modifiers/intern/MOD_fracture.c
index 1602e8c..ac4ab44 100644
--- a/source/blender/modifiers/intern/MOD_fracture.c
+++ b/source/blender/modifiers/intern/MOD_fracture.c
@@ -2234,9 +2234,9 @@ static void search_tree_based(FractureModifierData *rmd, MeshIsland *mi, MeshIsl
 
 	limit = rmd->constraint_limit;
 	dist = rmd->contact_dist;
-	factor = 1.0f - rmd->mass_threshold_factor;
+	factor = rmd->mass_threshold_factor;
 
-	if (factor > 0.0f && rmd->mass_threshold_factor > 0.0f && rmd->use_compounds) {
+	if (factor > 0.0f && rmd->use_compounds) {
 		if (mi->rigidbody->mass > 0.0f && max_mass > 0.0f) {
 			float ratio = mi->rigidbody->mass / max_mass;
 			dist *= (factor * ratio);




More information about the Bf-blender-cvs mailing list