Commit: 83b386220c6eecb661d9c1f2c8e39a3603412550
Author: Martin Felke
Date:   Tue Aug 7 23:47:47 2018 +0200
Branches: temp-fracture-modifier-2.8
https://developer.blender.org/rB83b386220c6eecb661d9c1f2c8e39a3603412550

trying to get it working again, temporarily

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

M       release/scripts/startup/bl_ui/properties_physics_fracture.py
M       source/blender/blenloader/intern/readfile.c
M       source/blender/makesdna/DNA_modifier_types.h
M       source/blender/modifiers/intern/MOD_fracture.c

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

diff --git a/release/scripts/startup/bl_ui/properties_physics_fracture.py 
b/release/scripts/startup/bl_ui/properties_physics_fracture.py
index cb180232705..f6b8faac586 100644
--- a/release/scripts/startup/bl_ui/properties_physics_fracture.py
+++ b/release/scripts/startup/bl_ui/properties_physics_fracture.py
@@ -112,7 +112,7 @@ class PHYSICS_PT_fracture(PhysicButtonsPanel, Panel):
         if md.frac_algorithm in {'BOOLEAN', 'BISECT_FILL', 'BISECT_FAST_FILL', 
'BOOLEAN_FRACTAL'}:
             col = layout.column()
             col.prop(md, "inner_material")
-            col.prop_search(md, "uv_layer", ob.data, "uv_textures")
+            col.prop_search(md, "uv_layer", ob.data, "uv_layers")
         if md.frac_algorithm == 'BOOLEAN_FRACTAL':
             col = layout.column(align=True)
             row = col.row(align=True)
diff --git a/source/blender/blenloader/intern/readfile.c 
b/source/blender/blenloader/intern/readfile.c
index 6a4ab649c5c..38ab967f2d5 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -9013,19 +9013,6 @@ static BHead *read_userdef(BlendFileData *bfd, FileData 
*fd, BHead *bhead)
        return bhead;
 }
 
-static void fix_fracture_image_hack(Main* main)
-{
-       Object *ob;
-
-       for (ob = main->object.first; ob; ob = ob->id.next) {
-               FractureModifierData *fmd = 
(FractureModifierData*)modifiers_findByType(ob, eModifierType_Fracture);
-               if (fmd && fmd->dm_group) {
-                       fmd->refresh_images = true;
-                       fmd->refresh = true;
-               }
-       }
-}
-
 BlendFileData *blo_read_file_internal(FileData *fd, const char *filepath)
 {
        BHead *bhead = blo_firstbhead(fd);
@@ -9126,8 +9113,6 @@ BlendFileData *blo_read_file_internal(FileData *fd, const 
char *filepath)
 
        lib_link_all(fd, bfd->main);
 
-       fix_fracture_image_hack(bfd->main);
-
        /* Skip in undo case. */
        if (fd->memfile == NULL) {
                /* Yep, second splitting... but this is a very cheap operation, 
so no big deal. */
diff --git a/source/blender/makesdna/DNA_modifier_types.h 
b/source/blender/makesdna/DNA_modifier_types.h
index e94a704db2b..0da4bbd8c69 100644
--- a/source/blender/makesdna/DNA_modifier_types.h
+++ b/source/blender/makesdna/DNA_modifier_types.h
@@ -90,7 +90,7 @@ typedef enum ModifierType {
        eModifierType_CorrectiveSmooth  = 51,
        eModifierType_MeshSequenceCache = 52,
        eModifierType_SurfaceDeform     = 53,
-       eModifierType_Fracture          = (1 << 20),
+    eModifierType_Fracture          = 54,
        NUM_MODIFIER_TYPES
 } ModifierType;
 
diff --git a/source/blender/modifiers/intern/MOD_fracture.c 
b/source/blender/modifiers/intern/MOD_fracture.c
index 792d55488a1..ea07e581b47 100644
--- a/source/blender/modifiers/intern/MOD_fracture.c
+++ b/source/blender/modifiers/intern/MOD_fracture.c
@@ -238,7 +238,7 @@ static void copyData(ModifierData *md, ModifierData *target)
        trmd->use_mass_dependent_thresholds = 
rmd->use_mass_dependent_thresholds;
        trmd->explo_shared = rmd->explo_shared;
 
-       trmd->refresh = true; //ensure valid data ?
+    trmd->refresh = false; //ensure valid data ?
        trmd->constraint_limit = rmd->constraint_limit;
        trmd->breaking_angle = rmd->breaking_angle;
        trmd->breaking_distance = rmd->breaking_distance;
@@ -440,7 +440,7 @@ static void updateDepsgraph(ModifierData *md, const 
ModifierUpdateDepsgraphConte
 
 
     /* We need own transformation as well. */
-    DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, 
"Fracture Modifier");
+    //DEG_add_object_relation(ctx->node, ctx->object, DEG_OB_COMP_TRANSFORM, 
"Fracture Modifier");
 }
 
 static void foreachObjectLink(
@@ -496,7 +496,7 @@ static Mesh *applyModifier(ModifierData *md, const 
ModifierEvalContext *ctx, Mes
     Mesh *pack_dm = BKE_fracture_mesh_from_packdata(fmd, derivedData);
     Mesh *final_dm = derivedData;
     Object* ob = ctx->object;
-    Scene* scene = DEG_get_input_scene(ctx->depsgraph); //or evaluated ?
+    Scene* scene = DEG_get_evaluated_scene(ctx->depsgraph); //or evaluated ?
 
        if (fmd->fracture_mode == MOD_FRACTURE_PREFRACTURED)
        {

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to