Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2018-06-22 16:03:42 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2018-06-22 16:12:03 +0300
commita7ca8fe1dd111f0b99c1b17cdd6b0f7e1c6f987b (patch)
tree98d27b8d18a21c6389f3090b0f8d92c6b5f595e0 /source/blender/modifiers/intern/MOD_displace.c
parent7a4b784909b3d31f318f92ddcfd534223f3e8412 (diff)
Modifiers: Remove lots of usages of md->scene
Diffstat (limited to 'source/blender/modifiers/intern/MOD_displace.c')
-rw-r--r--source/blender/modifiers/intern/MOD_displace.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/modifiers/intern/MOD_displace.c b/source/blender/modifiers/intern/MOD_displace.c
index 28791899e02..351a496daa1 100644
--- a/source/blender/modifiers/intern/MOD_displace.c
+++ b/source/blender/modifiers/intern/MOD_displace.c
@@ -53,6 +53,7 @@
#include "BKE_object.h"
#include "DEG_depsgraph.h"
+#include "DEG_depsgraph_query.h"
#include "MEM_guardedalloc.h"
@@ -159,6 +160,7 @@ static void updateDepsgraph(ModifierData *md, const ModifierUpdateDepsgraphConte
typedef struct DisplaceUserdata {
/*const*/ DisplaceModifierData *dmd;
+ struct Scene *scene;
struct ImagePool *pool;
MDeformVert *dvert;
float weight;
@@ -205,7 +207,7 @@ static void displaceModifier_do_task(
if (dmd->texture) {
texres.nor = NULL;
- BKE_texture_get_value_ex(dmd->modifier.scene, dmd->texture, tex_co[iter], &texres, data->pool, false);
+ BKE_texture_get_value_ex(data->scene, dmd->texture, tex_co[iter], &texres, data->pool, false);
delta = texres.tin - dmd->midlevel;
}
else {
@@ -330,6 +332,7 @@ static void displaceModifier_do(
}
DisplaceUserdata data = {NULL};
+ data.scene = DEG_get_evaluated_scene(ctx->depsgraph);
data.dmd = dmd;
data.dvert = dvert;
data.weight = weight;