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:
authorLuca Rood <dev@lucarood.com>2018-09-14 16:46:55 +0300
committerLuca Rood <dev@lucarood.com>2018-09-14 16:52:00 +0300
commitc4ef2e2f2ebcd9967aa5d4b283ac7abe51156d51 (patch)
tree031fed256c5ccb0428011a583535f37a88e2eb27 /source/blender/blenloader
parent1287965089a851c46e9a1a23c55ebc90b00b4e14 (diff)
Cloth: Improve UI
This reorganizes the cloth UI, and changes some of the behaviour to be more reasonable. Changes included here: * Reorganized cloth panels * Improved some tooltips * Removed `vel_damping` option * Removed cloth pinning checkbox * Removed stiffness scaling checkbox * Separated shrinking from sewing * Separated self collisions from object collisions Reviewed By: brecht Differential Revision: http://developer.blender.org/D3691
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/versioning_280.c29
1 files changed, 27 insertions, 2 deletions
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c
index 3cf65330b3e..e763f234f2e 100644
--- a/source/blender/blenloader/intern/versioning_280.c
+++ b/source/blender/blenloader/intern/versioning_280.c
@@ -1875,9 +1875,7 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *bmain)
}
}
}
- }
- {
/* Versioning code for Subsurf modifier. */
if (!DNA_struct_elem_find(fd->filesdna, "SubsurfModifier", "short", "uv_smooth")) {
for (Object *object = bmain->object.first; object != NULL; object = object->id.next) {
@@ -1956,5 +1954,32 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *bmain)
}
}
}
+
+ for (Object *ob = bmain->object.first; ob; ob = ob->id.next) {
+ for (ModifierData *md = ob->modifiers.first; md; md = md->next) {
+ if (md->type == eModifierType_Cloth) {
+ ClothModifierData *clmd = (ClothModifierData *)md;
+
+ if (!(clmd->sim_parms->flags & CLOTH_SIMSETTINGS_FLAG_GOAL)) {
+ clmd->sim_parms->vgroup_mass = 0;
+ }
+
+ if (!(clmd->sim_parms->flags & CLOTH_SIMSETTINGS_FLAG_SCALING)) {
+ clmd->sim_parms->vgroup_struct = 0;
+ clmd->sim_parms->vgroup_shear = 0;
+ clmd->sim_parms->vgroup_bend = 0;
+ }
+
+ if (!(clmd->sim_parms->flags & CLOTH_SIMSETTINGS_FLAG_SEW)) {
+ clmd->sim_parms->shrink_min = 0.0f;
+ clmd->sim_parms->vgroup_shrink = 0;
+ }
+
+ if (!(clmd->coll_parms->flags & CLOTH_COLLSETTINGS_FLAG_ENABLED)) {
+ clmd->coll_parms->flags &= ~CLOTH_COLLSETTINGS_FLAG_SELF;
+ }
+ }
+ }
+ }
}
}