diff options
author | Janne Karhu <jhkarh@gmail.com> | 2010-11-07 01:23:37 +0300 |
---|---|---|
committer | Janne Karhu <jhkarh@gmail.com> | 2010-11-07 01:23:37 +0300 |
commit | f793b75dcc3e6673b31f4bc60ee1e06db609e47c (patch) | |
tree | 3738cfa9f2118f98333bce28ee5fa701944b9522 /source/blender/editors/animation | |
parent | b0e62b0351bf056f4f5b8454c70ee1c24bad35c9 (diff) |
Fix for [#24476] The driver is not displayed in GraphEditor.
* TSK! give_current_material(..) is used with index+1
* Also very bad practice to use same loop variable name in a loop inside a loop.
Diffstat (limited to 'source/blender/editors/animation')
-rw-r--r-- | source/blender/editors/animation/anim_filter.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/animation/anim_filter.c b/source/blender/editors/animation/anim_filter.c index 08b4f8a7bc8..0e61d761463 100644 --- a/source/blender/editors/animation/anim_filter.c +++ b/source/blender/editors/animation/anim_filter.c @@ -1394,9 +1394,9 @@ static int animdata_filter_dopesheet_mats (bAnimContext *ac, ListBase *anim_data /* need to check textures */ if(ma->mtex) { MTex **mtex = ma->mtex; - int a; - for (a=0; a < MAX_MTEX; a++) { - if (ELEM3(NULL, mtex[a], mtex[a]->tex, mtex[a]->tex->adt)) + int mtInd; + for (mtInd=0; mtInd < MAX_MTEX; mtInd++) { + if (ELEM3(NULL, mtex[mtInd], mtex[mtInd]->tex, mtex[mtInd]->tex->adt)) continue; else ok=1; @@ -2206,7 +2206,7 @@ static int animdata_filter_dopesheet (bAnimContext *ac, ListBase *anim_data, bDo int a; /* firstly check that we actuallly have some materials */ - for (a=0; a < ob->totcol; a++) { + for (a=1; a <= ob->totcol; a++) { Material *ma= give_current_material(ob, a); if (ma) { @@ -2411,7 +2411,7 @@ static int animdata_filter_dopesheet (bAnimContext *ac, ListBase *anim_data, bDo int a; /* firstly check that we actuallly have some materials */ - for (a=0; a < ob->totcol; a++) { + for (a=1; a <= ob->totcol; a++) { Material *ma= give_current_material(ob, a); int mtInd; |