diff options
-rw-r--r-- | src/llr/llr.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/llr/llr.c b/src/llr/llr.c index 74cfaed..e5242e7 100644 --- a/src/llr/llr.c +++ b/src/llr/llr.c | |||
@@ -36,11 +36,14 @@ static bool init_ibl(LLR* renderer) { | |||
36 | return true; | 36 | return true; |
37 | } | 37 | } |
38 | 38 | ||
39 | // TODO: Why is this done lazily here? Do it when the environment light is | ||
40 | // created. | ||
41 | // | ||
42 | /// Compute irradiance and prefiltered environment maps for the light if they | 39 | /// Compute irradiance and prefiltered environment maps for the light if they |
43 | /// have not been already computed. | 40 | /// have not been already computed. |
41 | /// | ||
42 | /// This is done lazily here, and not when the light is created, because we | ||
43 | /// need an IBL instance to do this and it is more convenient for the public | ||
44 | /// API to create lights without worrying about those details. It also makes the | ||
45 | /// public API cheaper, since the maps are only computed when they are actually | ||
46 | /// needed. | ||
44 | static bool set_up_environment_light(LLR* renderer, EnvironmentLight* light) { | 47 | static bool set_up_environment_light(LLR* renderer, EnvironmentLight* light) { |
45 | assert(renderer); | 48 | assert(renderer); |
46 | assert(light); | 49 | assert(light); |