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
path: root/source
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2013-05-03 12:37:18 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-05-03 12:37:18 +0400
commit0e27e7196227be21359a69078ccebba4cfcd70e8 (patch)
treefe890824d2f6581953a9b8cfe407659e409bf9ca /source
parenta947ea0a1eb6092ba76c27ee6613d17548ed3321 (diff)
correct own recent commit, confused totloop with dm_totloop, rename vars & correct even though in this case the error was harmless.
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/intern/DerivedMesh.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/blenkernel/intern/DerivedMesh.c b/source/blender/blenkernel/intern/DerivedMesh.c
index ebe032ad827..8efd9ae133e 100644
--- a/source/blender/blenkernel/intern/DerivedMesh.c
+++ b/source/blender/blenkernel/intern/DerivedMesh.c
@@ -1244,22 +1244,22 @@ void DM_update_weight_mcol(Object *ob, DerivedMesh *dm, int const draw_flag,
unsigned char(*wtcol_l)[4] = CustomData_get_layer(dm->getLoopDataLayout(dm), CD_PREVIEW_MLOOPCOL);
MLoop *mloop = dm->getLoopArray(dm), *ml;
MPoly *mp = dm->getPolyArray(dm);
- int totloop;
+ int l_index;
int j;
/* now add to loops, so the data can be passed through the modifier stack */
/* If no CD_PREVIEW_MLOOPCOL existed yet, we have to add a new one! */
if (!wtcol_l) {
wtcol_l = MEM_mallocN(sizeof(*wtcol_l) * dm_totloop, __func__);
- CustomData_add_layer(&dm->loopData, CD_PREVIEW_MLOOPCOL, CD_ASSIGN, wtcol_l, totloop);
+ CustomData_add_layer(&dm->loopData, CD_PREVIEW_MLOOPCOL, CD_ASSIGN, wtcol_l, dm_totloop);
}
- totloop = 0;
+ l_index = 0;
for (i = 0; i < dm_totpoly; i++, mp++) {
ml = mloop + mp->loopstart;
- for (j = 0; j < mp->totloop; j++, ml++, totloop++) {
- copy_v4_v4_char((char *)&wtcol_l[totloop],
+ for (j = 0; j < mp->totloop; j++, ml++, l_index++) {
+ copy_v4_v4_char((char *)&wtcol_l[l_index],
(char *)&wtcol_v[ml->v]);
}
}