ADD: Lighting modifier and IBL probe

This commit is contained in:
2025-11-27 21:49:25 +09:00
parent 2182b02f4a
commit 67ab04f798
11 changed files with 401 additions and 45 deletions

View File

@@ -37,6 +37,36 @@ void SceneManager::clearPointLights()
pointLights.clear();
}
bool SceneManager::getPointLight(size_t index, PointLight &outLight) const
{
if (index >= pointLights.size())
{
return false;
}
outLight = pointLights[index];
return true;
}
bool SceneManager::setPointLight(size_t index, const PointLight &light)
{
if (index >= pointLights.size())
{
return false;
}
pointLights[index] = light;
return true;
}
bool SceneManager::removePointLight(size_t index)
{
if (index >= pointLights.size())
{
return false;
}
pointLights.erase(pointLights.begin() + index);
return true;
}
void SceneManager::init(EngineContext *context)
{
_context = context;

View File

@@ -136,6 +136,10 @@ public:
void addPointLight(const PointLight &light);
void clearPointLights();
size_t getPointLightCount() const { return pointLights.size(); }
bool getPointLight(size_t index, PointLight &outLight) const;
bool setPointLight(size_t index, const PointLight &light);
bool removePointLight(size_t index);
const std::vector<PointLight> &getPointLights() const { return pointLights; }
struct SceneStats