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:
authorGaia Clary <gaia.clary@machinimatrix.org>2012-06-13 03:19:34 +0400
committerGaia Clary <gaia.clary@machinimatrix.org>2012-06-13 03:19:34 +0400
commitb0038ae4996993f1dd808babe402e2e390933330 (patch)
treee7b234532fe2cbf48f809c6ae027162d0361972c /source/blender/collada/MaterialExporter.cpp
parentc7cca0c842e05a4fc2f5946844d212a365c5ab47 (diff)
Collada: fixed a few loops to only loop over the list of exported objects, instead of the current scene.
Diffstat (limited to 'source/blender/collada/MaterialExporter.cpp')
-rw-r--r--source/blender/collada/MaterialExporter.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/source/blender/collada/MaterialExporter.cpp b/source/blender/collada/MaterialExporter.cpp
index 106861c1916..ef22a76d28e 100644
--- a/source/blender/collada/MaterialExporter.cpp
+++ b/source/blender/collada/MaterialExporter.cpp
@@ -46,13 +46,11 @@ void MaterialsExporter::exportMaterials(Scene *sce)
}
}
-/* TODO - shouldn't this use the scenes object LinkNode's ? */
bool MaterialsExporter::hasMaterials(Scene *sce)
{
- Base *base = (Base *)sce->base.first;
-
- while (base) {
- Object *ob = base->object;
+ LinkNode *node;
+ for(node=this->export_settings->export_set; node; node = node->next) {
+ Object *ob = (Object *)node->link;
int a;
for (a = 0; a < ob->totcol; a++) {
Material *ma = give_current_material(ob, a + 1);
@@ -62,7 +60,6 @@ bool MaterialsExporter::hasMaterials(Scene *sce)
return true;
}
- base = base->next;
}
return false;
}