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:
Diffstat (limited to 'source/blender/gpencil_modifiers/intern/MOD_gpencillattice.c')
-rw-r--r--source/blender/gpencil_modifiers/intern/MOD_gpencillattice.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/gpencil_modifiers/intern/MOD_gpencillattice.c b/source/blender/gpencil_modifiers/intern/MOD_gpencillattice.c
index d5295fc7306..765967d8346 100644
--- a/source/blender/gpencil_modifiers/intern/MOD_gpencillattice.c
+++ b/source/blender/gpencil_modifiers/intern/MOD_gpencillattice.c
@@ -169,7 +169,12 @@ static bool isDisabled(GpencilModifierData *md, int UNUSED(userRenderParams))
{
LatticeGpencilModifierData *mmd = (LatticeGpencilModifierData *)md;
- return !mmd->object;
+ /* The object type check is only needed here in case we have a placeholder
+ * object assigned (because the library containing the lattice is missing).
+ *
+ * In other cases it should be impossible to have a type missmatch.
+ */
+ return !mmd->object || mmd->object->type != OB_LATTICE;
}
static void updateDepsgraph(GpencilModifierData *md, const ModifierUpdateDepsgraphContext *ctx)