Thank you
Sorry to bump this!
Question for anyone familiar with JME shadow!
I was looking at JME shadow and looks like it does also use the same hack of extending the bound? but why only in the Z axis?
and what bout the issues pointed out by pspeed regarding using this trick, how JME manages it?
I spent too much time in that code part. lucky for you i understood most of it.
Right before the z extension the occBox is transformed into light perspective. increasing the ZExtent extents it nearer to the light origin, and at the same time will likely cover the actual view frustum. (which it might not otherwise due to light transform)
I say likely, because this hack is quite dirty. It will not render any shadows that are more then 50 units away. It hopes that adding 50 to “fustum far” will cover all of the view frustum
This is the point the light angle comes into play. At low light angles (in a flat world) objects casting shadows more than 50+x long will not be rendered. Jme simply does not care about those issues as far i understood
Hmm, do we need to add a new shadow renderer per each directional/point light?
Yeah that is how jme shadows unfortunately work.
Is this also the same in deferred?
At least for point/spotlights i am fairly sure i keep the current implentation. Directional shadows are a magnitude more complex. it is still very bugged so i am not sure if the current design holds.
But no, in my implementation you basically have to enable shadow casting on the Extended*Light and thats it.
It is however still in the very early stages of development.