improvements to lighting engine