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:
authorSergey Sharybin <sergey.vfx@gmail.com>2013-08-19 14:11:48 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2013-08-19 14:11:48 +0400
commitc46cbc602e1007a15c6d9824ec34c41f124faeaa (patch)
tree3cc89f89a2601d7a8de18ef39b7207803b5f75fd /source/blender/makesdna
parentb9ae749480aeeb7e77f16ebe667ddfcf8b63650e (diff)
Make lattice deform safe for threading
Lattice deformation used to store some runtime data inside of lattice datablock itself. It's something which is REALLY bad. Ideally DNA shouldn't contain and runtime data. For now solved it in a way that initialization of lattice deform will create a structure which contains lattice object for which deformation is calculating and that runtime data which used to be stored in lattice datablock itself. It works really fine for mesh deform modifier, but there's still runtime data stored in particle system DNA, It didn't look something easy to be solved, so leaving this as-is for now. -- svn merge -r58277:58278 -r58795:58796 ^/branches/soc-2013-depsgraph_mt
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_lattice_types.h4
-rw-r--r--source/blender/makesdna/DNA_particle_types.h4
2 files changed, 3 insertions, 5 deletions
diff --git a/source/blender/makesdna/DNA_lattice_types.h b/source/blender/makesdna/DNA_lattice_types.h
index 837f0c354e6..242d6f0feeb 100644
--- a/source/blender/makesdna/DNA_lattice_types.h
+++ b/source/blender/makesdna/DNA_lattice_types.h
@@ -68,10 +68,6 @@ typedef struct Lattice {
struct MDeformVert *dvert;
char vgroup[64]; /* multiply the influence, MAX_VGROUP_NAME */
- /* used while deforming, always free and NULL after use */
- float *latticedata;
- float latmat[4][4];
-
struct EditLatt *editlatt;
} Lattice;
diff --git a/source/blender/makesdna/DNA_particle_types.h b/source/blender/makesdna/DNA_particle_types.h
index 29fcaf3bf73..b7ca3066b4f 100644
--- a/source/blender/makesdna/DNA_particle_types.h
+++ b/source/blender/makesdna/DNA_particle_types.h
@@ -272,7 +272,9 @@ typedef struct ParticleSystem {
struct DerivedMesh *hair_in_dm, *hair_out_dm; /* input/output for cloth simulation */
struct Object *target_ob;
- struct Object *lattice;
+
+ struct LatticeDeformData *lattice_deform_data; /* run-time only lattice deformation data */
+
struct Object *parent; /* particles from global space -> parent space */
struct ListBase targets; /* used for keyed and boid physics */