[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [22121] branches/soc-2009-chingachgook/ source/blender/collada/DocumentExporter.cpp: Small fix to lights export.
Chingiz Dyussenov
chingiz.ds at gmail.com
Sat Aug 1 19:08:18 CEST 2009
Revision: 22121
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=22121
Author: chingachgook
Date: 2009-08-01 19:08:18 +0200 (Sat, 01 Aug 2009)
Log Message:
-----------
Small fix to lights export.
Modified Paths:
--------------
branches/soc-2009-chingachgook/source/blender/collada/DocumentExporter.cpp
Modified: branches/soc-2009-chingachgook/source/blender/collada/DocumentExporter.cpp
===================================================================
--- branches/soc-2009-chingachgook/source/blender/collada/DocumentExporter.cpp 2009-08-01 13:13:44 UTC (rev 22120)
+++ branches/soc-2009-chingachgook/source/blender/collada/DocumentExporter.cpp 2009-08-01 17:08:18 UTC (rev 22121)
@@ -913,7 +913,7 @@
// write node for child object
Base *b = (Base*) sce->base.first;
while(b) {
-
+ // cob - child object
Object *cob = b->object;
if ((cob->type == OB_MESH || cob->type == OB_CAMERA || cob->type == OB_LAMP || cob->type == OB_EMPTY) && cob->parent == ob) {
@@ -1252,7 +1252,6 @@
}
};
-#if 0
class LightsExporter: COLLADASW::LibraryLights
{
public:
@@ -1273,26 +1272,26 @@
// sun
if (la->type == LA_SUN) {
- COLLADASW::DirectionalLight cla(mSW, la_name, la->energy);
+ COLLADASW::DirectionalLight cla(mSW, la_name, "", la->energy);
cla.setColor(col);
addLight(cla);
}
// hemi
else if (la->type == LA_HEMI) {
- COLLADASW::AmbientLight cla(mSW, la_name, la->energy);
+ COLLADASW::AmbientLight cla(mSW, la_name, "", la->energy);
cla.setColor(col);
addLight(cla);
}
// spot
// XXX add other params later
else if (la->type == LA_SPOT) {
- COLLADASW::SpotLight cla(mSW, la_name, la->energy);
+ COLLADASW::SpotLight cla(mSW, la_name, "", la->energy);
cla.setColor(col);
addLight(cla);
}
// lamp
else if (la->type != LA_AREA) {
- COLLADASW::PointLight cla(mSW, la_name, la->energy);
+ COLLADASW::PointLight cla(mSW, la_name, "", la->energy);
cla.setColor(col);
addLight(cla);
}
@@ -1302,7 +1301,6 @@
}
}
};
-#endif
// TODO: it would be better to instantiate animations rather than create a new one per object
// COLLADA allows this through multiple <channel>s in <animation>.
@@ -1547,11 +1545,9 @@
CamerasExporter ce(&sw);
ce.exportCameras(sce);
-#if 0
// <library_lights>
LightsExporter le(&sw);
le.exportLights(sce);
-#endif
// <library_images>
ImagesExporter ie(&sw);
More information about the Bf-blender-cvs
mailing list