@@ -366,31 +366,31 @@ void RecordTraversal::apply(const AmbientLight& light)
366366 CPU_INSTRUMENTATION_L2_O (instrumentation, &light);
367367
368368 // debug("RecordTraversal::apply(AmbientLight) ", light.className());
369- if (_viewDependentState) _viewDependentState->ambientLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
369+ if (light. intensity >= intensityMinimum && _viewDependentState) _viewDependentState->ambientLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
370370}
371371
372372void RecordTraversal::apply (const DirectionalLight& light)
373373{
374374 CPU_INSTRUMENTATION_L2_O (instrumentation, &light);
375375
376376 // debug("RecordTraversal::apply(DirectionalLight) ", light.className());
377- if (_viewDependentState) _viewDependentState->directionalLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
377+ if (light. intensity >= intensityMinimum && _viewDependentState) _viewDependentState->directionalLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
378378}
379379
380380void RecordTraversal::apply (const PointLight& light)
381381{
382382 CPU_INSTRUMENTATION_L2_O (instrumentation, &light);
383383
384384 // debug("RecordTraversal::apply(PointLight) ", light.className());
385- if (_viewDependentState) _viewDependentState->pointLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
385+ if (light. intensity >= intensityMinimum && _viewDependentState) _viewDependentState->pointLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
386386}
387387
388388void RecordTraversal::apply (const SpotLight& light)
389389{
390390 CPU_INSTRUMENTATION_L2_O (instrumentation, &light);
391391
392392 // debug("RecordTraversal::apply(SpotLight) ", light.className());
393- if (_viewDependentState) _viewDependentState->spotLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
393+ if (light. intensity >= intensityMinimum && _viewDependentState) _viewDependentState->spotLights .emplace_back (_state->modelviewMatrixStack .top (), &light);
394394}
395395
396396// transform nodes
0 commit comments