| 18 | } |
| 19 | |
| 20 | bool ShadowsOfMordor::Builder::LightmapBuildCache::Init(const LightmapSettings* settings) |
| 21 | { |
| 22 | if (LightmapData) |
| 23 | return false; |
| 24 | LightmapData = GPUDevice::Instance->CreateBuffer(TEXT("LightmapBuildCache")); |
| 25 | const auto elementsCount = (int32)settings->AtlasSize * (int32)settings->AtlasSize * NUM_SH_TARGETS; |
| 26 | if (LightmapData->Init(GPUBufferDescription::Typed(elementsCount, HemispheresFormatToPixelFormat[HEMISPHERES_IRRADIANCE_FORMAT], true))) |
| 27 | return true; |
| 28 | return false; |
| 29 | } |
| 30 | |
| 31 | ShadowsOfMordor::Builder::SceneBuildCache::SceneBuildCache() |
| 32 | : Scene(nullptr) |
no test coverage detected