42 DeferredLightList::iterator iDeferredLight = deferredLightList.begin();
43 while(iDeferredLight != deferredLightList.end())
45 iDeferredLight->first->setListener(0);
46 delete(iDeferredLight->second);
48 deferredLightList.clear();
50 SO3_SAFE_DELETE(deferredLightDirectionalMaterialGenerator);
51 SO3_SAFE_DELETE(deferredLightPointMaterialGenerator);
52 SO3_SAFE_DELETE(deferredLightSpotMaterialGenerator);
53 SO3_SAFE_DELETE(deferredLightAmbientMaterialGenerator);
69 DeferredLightList::iterator iSearchedDeferredLight = deferredLightList.find(existingLight);
70 if(iSearchedDeferredLight != deferredLightList.end())
72 return iSearchedDeferredLight->second;
77 deferredLightList[existingLight] = newDeferredLight;
78 existingLight->setListener(
this);
79 return newDeferredLight;
85 DeferredLightList::iterator iSearchedDeferredLight = deferredLightList.find(
static_cast<Ogre::Light*
>(light));
86 if(iSearchedDeferredLight != deferredLightList.end())
88 light->setListener(0);
89 delete(iSearchedDeferredLight->second);
90 deferredLightList.erase(iSearchedDeferredLight);