diff options
author | Dalai Felinto <dalai@blender.org> | 2020-11-14 03:36:47 +0300 |
---|---|---|
committer | Dalai Felinto <dalai@blender.org> | 2020-11-14 03:51:06 +0300 |
commit | e50553c61a2d0331b650d2d3d54ef9cb479eebd5 (patch) | |
tree | facd5f7e99e2d4eac32bb51943cce65152d77094 | |
parent | b458ea6b23381a9acb90dbbd73ced678e1d404c5 (diff) |
Empty Modifier: Fix build and put in the right order
Bypassing the macro that creates modifiers to allow the enum to be
referring to the Empty modifier, but the internal struct in the code to
be Nodes.
Also fix the name of the new created modifiers to be "Empty".
Fix was built with rBb458ea6b23381a9acb90dbbd73ced678e1d404c5.
-rw-r--r-- | source/blender/makesrna/intern/rna_modifier.c | 2 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_nodes.cc | 2 | ||||
-rw-r--r-- | source/blender/modifiers/intern/MOD_util.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/makesrna/intern/rna_modifier.c b/source/blender/makesrna/intern/rna_modifier.c index 5b3bd61a1a4..5b21fdb9cec 100644 --- a/source/blender/makesrna/intern/rna_modifier.c +++ b/source/blender/makesrna/intern/rna_modifier.c @@ -143,6 +143,7 @@ const EnumPropertyItem rna_enum_object_modifier_type_items[] = { ICON_MOD_EDGESPLIT, "Edge Split", "Split away joined faces at the edges"}, + {eModifierType_Empty, "EMPTY", ICON_MESH_DATA, "Empty", ""}, /* TODO: Use correct icon. */ {eModifierType_Mask, "MASK", ICON_MOD_MASK, @@ -163,7 +164,6 @@ const EnumPropertyItem rna_enum_object_modifier_type_items[] = { ICON_MOD_MULTIRES, "Multiresolution", "Subdivide the mesh in a way that allows editing the higher subdivision levels"}, - {eModifierType_Empty, "EMPTY", ICON_MESH_DATA, "Empty", ""}, /* TODO: Use correct icon. */ {eModifierType_Remesh, "REMESH", ICON_MOD_REMESH, diff --git a/source/blender/modifiers/intern/MOD_nodes.cc b/source/blender/modifiers/intern/MOD_nodes.cc index 6dfc2f2bdba..4204b0e1013 100644 --- a/source/blender/modifiers/intern/MOD_nodes.cc +++ b/source/blender/modifiers/intern/MOD_nodes.cc @@ -987,7 +987,7 @@ static void freeData(ModifierData *md) } ModifierTypeInfo modifierType_Nodes = { - /* name */ "Nodes", + /* name */ "Empty", /* structName */ "NodesModifierData", /* structSize */ sizeof(NodesModifierData), #ifdef WITH_GEOMETRY_NODES diff --git a/source/blender/modifiers/intern/MOD_util.c b/source/blender/modifiers/intern/MOD_util.c index 32d40027537..611d6de72da 100644 --- a/source/blender/modifiers/intern/MOD_util.c +++ b/source/blender/modifiers/intern/MOD_util.c @@ -342,9 +342,9 @@ void modifier_type_init(ModifierTypeInfo *types[]) INIT_TYPE(MeshSequenceCache); INIT_TYPE(SurfaceDeform); INIT_TYPE(WeightedNormal); - INIT_TYPE(Nodes); INIT_TYPE(MeshToVolume); INIT_TYPE(VolumeDisplace); INIT_TYPE(VolumeToMesh); #undef INIT_TYPE + types[eModifierType_Empty] = &modifierType_Nodes; } |