diff options
Diffstat (limited to 'source/blender/editors/physics')
-rw-r--r-- | source/blender/editors/physics/particle_edit_undo.c | 7 | ||||
-rw-r--r-- | source/blender/editors/physics/particle_object.c | 5 |
2 files changed, 6 insertions, 6 deletions
diff --git a/source/blender/editors/physics/particle_edit_undo.c b/source/blender/editors/physics/particle_edit_undo.c index 205c04f54a9..8db6c4c853e 100644 --- a/source/blender/editors/physics/particle_edit_undo.c +++ b/source/blender/editors/physics/particle_edit_undo.c @@ -57,7 +57,6 @@ static void undoptcache_from_editcache(PTCacheUndo *undo, PTCacheEdit *edit) { PTCacheEditPoint *point; - int i; size_t mem_used_prev = MEM_get_memory_in_use(); @@ -68,7 +67,7 @@ static void undoptcache_from_editcache(PTCacheUndo *undo, PTCacheEdit *edit) pa = undo->particles = MEM_dupallocN(edit->psys->particles); - for (i = 0; i < edit->totpoint; i++, pa++) { + for (int i = 0; i < edit->totpoint; i++, pa++) { pa->hair = MEM_dupallocN(pa->hair); } @@ -81,7 +80,7 @@ static void undoptcache_from_editcache(PTCacheUndo *undo, PTCacheEdit *edit) pm = undo->mem_cache.first; for (; pm; pm = pm->next) { - for (i = 0; i < BPHYS_TOT_DATA; i++) { + for (int i = 0; i < BPHYS_TOT_DATA; i++) { pm->data[i] = MEM_dupallocN(pm->data[i]); } } @@ -90,7 +89,7 @@ static void undoptcache_from_editcache(PTCacheUndo *undo, PTCacheEdit *edit) point = undo->points = MEM_dupallocN(edit->points); undo->totpoint = edit->totpoint; - for (i = 0; i < edit->totpoint; i++, point++) { + for (int i = 0; i < edit->totpoint; i++, point++) { point->keys = MEM_dupallocN(point->keys); /* no need to update edit key->co & key->time pointers here */ } diff --git a/source/blender/editors/physics/particle_object.c b/source/blender/editors/physics/particle_object.c index 41e30adf724..0eda5877bb4 100644 --- a/source/blender/editors/physics/particle_object.c +++ b/source/blender/editors/physics/particle_object.c @@ -721,7 +721,7 @@ static bool remap_hair_emitter(Depsgraph *depsgraph, MVert *mvert; Mesh *mesh, *target_mesh; int numverts; - int i, k; + int k; float from_ob_imat[4][4], to_ob_imat[4][4]; float from_imat[4][4], to_imat[4][4]; @@ -763,7 +763,7 @@ static bool remap_hair_emitter(Depsgraph *depsgraph, mvert = mesh->mvert; /* convert to global coordinates */ - for (i = 0; i < numverts; i++) { + for (int i = 0; i < numverts; i++) { mul_m4_v3(to_mat, mvert[i].co); } @@ -780,6 +780,7 @@ static bool remap_hair_emitter(Depsgraph *depsgraph, return false; } + int i; for (i = 0, tpa = target_psys->particles, pa = psys->particles; i < target_psys->totpart; i++, tpa++, pa++) { float from_co[3]; |