Gamua / Starling-Extension-Dynamic-Lighting

Use normal maps for realistic light effects in the Starling Framework.
Other
20 stars 3 forks source link

Feature request: Attenuation aspect on Point Light #1

Open Adolio opened 8 years ago

Adolio commented 8 years ago

It would be nice to take light attenuation into account for point lights.

Here is a common way to compute the attenuation based on two parameters that LightSource could provide:

att = 1.0 / (1.0 + linearAttenuationCoeff*dist + quadraticAttenuationCoeff*dist*dist)

Further info: http://gamedev.stackexchange.com/questions/56897/glsl-light-attenuation-color-and-intensity-formula

Thanks a lot for this extension Daniel :)

PrimaryFeather commented 8 years ago

You're right, that's the one part that's still missing — before working on that, I wanted to check if anyone is actually using the extension. :smile:

I'll look into it! In the meantime, anyone who needs this, please "+1" to let me know how to prioritize this feature.

lorenzobob0 commented 7 years ago

The Dynamic light extension is used and much appreciated.

This feature would be great!

Thank you for your work!

htmiel commented 1 year ago

This would be very useful and a great addition to an already excellent extension!

DrNeroCF commented 1 year ago

I hate to admit that I'm only looking into this now, but even in the default state it's still crazy to see this in AIR. The only real issue I have at the moment is point lights lighting backgrounds at full blast. Not the most difficult thing to just fade the light's influnce into the background layers, but I'm sure I'm doing it wrong and wouldn't be able to easily have lights in the background, or be able to move lights on the z axis.