KRObjView now automatically loads any models it finds in the "Documents" folder and assigns light maps that have the same name as the model appended with "_lightmap".

Lightmapping now enabled by default.

--HG--
extra : convert_revision : svn%3A7752d6cf-9f14-4ad2-affc-04f1e67b81a5/trunk%4026
This commit is contained in:
kearwood
2012-04-05 21:18:25 +00:00
parent ee3fbb8a8a
commit 75e42c08fd
4 changed files with 17 additions and 2 deletions

View File

@@ -127,7 +127,14 @@
//m_scene.addInstance(pModelManager->getModel("fachwerkhaus12"), KRMat4());
//m_scene.addInstance(pModelManager->getModel("ballroom"), KRMat4());
//m_scene.addInstance(pModelManager->getModel("HoganCombined"), KRMat4());
m_scene.addInstance(pModelManager->getModel("polySurface12848"), KRMat4(), "PillarLightmap2k");
//m_scene.addInstance(pModelManager->getModel("polySurface12848"), KRMat4(), "PillarLightmap2k");
std::map<std::string, KRModel *> models = pModelManager->getModels();
for(std::map<std::string, KRModel *>::iterator itr=models.begin(); itr != models.end(); itr++) {
std::string lightmap = (*itr).first;
lightmap.append("_lightmap");
m_scene.addInstance((*itr).second, KRMat4(), lightmap);
}
[renderEngine setNearZ: 25.0];
[renderEngine setFarZ: 5000.0];