diff options
author | Janne Karhu <jhkarh@gmail.com> | 2010-09-02 12:06:53 +0400 |
---|---|---|
committer | Janne Karhu <jhkarh@gmail.com> | 2010-09-02 12:06:53 +0400 |
commit | 5db18d474fa2c8b7176806368e5bc0aa68fef325 (patch) | |
tree | d914241547c9c076e966024cb59834d013b4ce42 /source/blender/editors/object/object_modifier.c | |
parent | 18954a711fc920da3933e71d7705f07337fd13eb (diff) |
"Fix" for [#23621] lattice modifier on particle hair when applied doesn't apply it to the hair
* Although not strictly a bug it is the expected behavior and won't mess anything else up.
* Note: the lattice is applied to the actual hair keys instead of the calculated strands so the applied result will differ a bit from the original.
Diffstat (limited to 'source/blender/editors/object/object_modifier.c')
-rw-r--r-- | source/blender/editors/object/object_modifier.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c index 286e953a69a..5cc6cb9107d 100644 --- a/source/blender/editors/object/object_modifier.c +++ b/source/blender/editors/object/object_modifier.c @@ -453,6 +453,21 @@ static int modifier_apply_obdata(ReportList *reports, Scene *scene, Object *ob, BKE_report(reports, RPT_ERROR, "Cannot apply modifier for this object type"); return 0; } + + /* lattice modifier can be applied to particle system too */ + if(ob->particlesystem.first) { + + ParticleSystem *psys = ob->particlesystem.first; + + for(; psys; psys=psys->next) { + + if(psys->part->type != PART_HAIR) + continue; + + psys_apply_hair_lattice(scene, ob, psys); + } + } + return 1; } |