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/modifiers/intern/MOD_smooth.c')
-rw-r--r--source/blender/modifiers/intern/MOD_smooth.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/modifiers/intern/MOD_smooth.c b/source/blender/modifiers/intern/MOD_smooth.c
index 7076721d8ce..f8e76d92615 100644
--- a/source/blender/modifiers/intern/MOD_smooth.c
+++ b/source/blender/modifiers/intern/MOD_smooth.c
@@ -29,6 +29,7 @@
#include "BLT_translation.h"
+#include "DNA_defaults.h"
#include "DNA_mesh_types.h"
#include "DNA_meshdata_types.h"
#include "DNA_screen_types.h"
@@ -55,10 +56,9 @@ static void initData(ModifierData *md)
{
SmoothModifierData *smd = (SmoothModifierData *)md;
- smd->fac = 0.5f;
- smd->repeat = 1;
- smd->flag = MOD_SMOOTH_X | MOD_SMOOTH_Y | MOD_SMOOTH_Z;
- smd->defgrp_name[0] = '\0';
+ BLI_assert(MEMCMP_STRUCT_AFTER_IS_ZERO(smd, modifier));
+
+ MEMCPY_STRUCT_AFTER(smd, DNA_struct_default_get(SmoothModifierData), modifier);
}
static bool isDisabled(const struct Scene *UNUSED(scene),