So after reading https://www.guerrilla-games.com/read/killzone-shadow-fall-creating-art-tools-for-a-new-generation & The moving to frostbite PBR presentation I noticed that Area lights as opposed to the standard Directional, Point & Spot lights can produce much better results.
Now a lot of the resources online talk about it and what it is but there's not much regarding implementation.
Can somebody explain how I can implement this (and maybe with some code). If you could include any links to some good resources regarding implementation that would be great as well. I've already checked out Brian Karis' Siggraph Presentation & Gpu Pro 5's chapter on it.
I have been told for a point light that instead of calculating the distance from a point, you simply calculate it from the rectangle.
For a point light finding the distance from the light to a surface is as easy as:
float3 lightVec = L.Position - pos;
But how would I do this for a rectangle?