Shadows shader performance oddness
expected
Andred Darwin
The only change between both screenshots is Shadows set from Sun/Moon to Sun/Moon + Projectors....
- No light projectors in the scene (other than Sun light).
- No visible/noticeable change on the scene rendered (using default environment @ land).
- A drop from 82 fps to 30 fps (with this 30 fps locked, no matter what resolution 1920x1080, 2560x1440, 3840x2160).
Transparency + Sun/Moon Projectors kill the experience for open areas, there are almost no areas like that right? ... (I sent Atlas and Kyle in the past several landmarks where the same is visible, and toggling the same Shadows option causes the same similar effect with different degrees of impact.. which is understandable, but almost 3 times slower? There is probably a huge opportunity with the viewer code for it... )
The area is empty, no avatars, no vendor textures or objects other than the area decor, its also not heavily decorated (will be an event area in the future).
If can't be fixed, could something be done to let the user know, by just switching Sun/Moon + Projectors to Sun/Moon only, your performance may increase considerably and still have the scene rendered the same way in open areas. (Maybe the other way, when turning on Sun Moon + Projectors, the scene will use considerably more resources, specially your CPU due to the ancient thread issue, causing your fans to spin like a jet stuck to a lower fps, hehehehehe.... )
If there are no projectors (other than Sun), no noticeable change in the scene rendered, why that pass/option is still killing performance?
Log In
Dan Linden
marked this post as
expected
Dan Linden
Hi Andred,
As observeur discovered, there are projectors in that space and that explains the change in performance. If this is your land, and it's never nighttime there, you might consider changing the lamps to be point lights to reduce the shadow tax. As for warning the user, the options are ordered from the most performance to least performant, and a warning is not necessary.
Andred Darwin
Dan Linden observeur Resident
Thank you for looking at it, its not my land, but I will "rent" there... I did not notice at all the lights were projectors, and even at night time environment, I didnt notice the shadows forming around, seems like it only shows it if you get really (av or camera) close to the light source itself.
I dont see a metadata option for projectors only under the Develop menu -> Render Metadata. Maybe would be worth an option for that to highlight projectors only....
I disagree with you that projectors dont need a warning, the performance is ridiculous, but I guess according to how you are marking this issue as Expected, its as expected as the results of the company...
Andred Darwin
Dan Linden
Even with a night environment, the scene from that camera position renders exactly the same way, it only changes if the camera goes really close to the floor, where the projector actually gets activated and generates the shadow... however, the whole scene is rendered with a much lower FPS.... if the damn shadows wont even be displayed, why tax the scene that much?
Its quite a disappointment to see it just dismissed as expected, any user that just invested a lot of money on their machine just to play games including Second Life at its highest resolution, will dismiss SL as a "piece of cr**", please raise this with whoever makes these decisions, it really makes no sense to have the viewer like this... it can be the other way, and show decent performance without pegging the CPU and FPS, specially when the scene will show differences only if close to the projector (if it can only render 2 projectors at a time, and 2 projectors cause an almost 3 times performance loss, why have projectors at all! )
How would an user know, their brand new, shiny, latest and greatest 5090 runs like sh**, just because they set their viewer to ultra and the scene has a few light projectors? Leave and dismiss?
observeur Resident
I went to this place. It has lamps all around that cast shadows, which won't be very visible with daylight windlight but are visible when using midnight (see capture). Fact is, projector shadows are indeed very heavy (sun shadows as well specially with long draw distance, as it has to redraw 4 splits of the scene in a depth buffer from the sun point of view). Projector shadows render the scene depth in 2 splits, but is dependant on the number of projectors. In this scene there are quite some projectors around, which is taxing performance enormously. I think, in the past, creators could set a light source to cast shadows or not, the option doesn't exist anymore. There sure is something to do about it optimisation wise.
One possible optimisation is to limit projector shadows to a close range, so only the closest light sources would cast shadows. Also maybe to give back control on which projector would cast shadows.
In megapahit i added some more control on the shadows draw distance, that helps a lot. I mostly focused on sun shadows, though. I might study more closely projectors because i also noticed a very severe impact in some scenes.
Andred Darwin
observeur Resident
Thank you for taking the time and noticing the projectors, I didnt noticed at all since I never pointed the camera close to one, I really appreciate you taking the time, was very helpful! ... For an event, the best optimization is probably remove those completely... or make them point lights is much less taxing than projectors....
observeur Resident
Andred Darwin You are welcome Andred.
The marvellous thing in SL is that anyone can add or modify the content, with or without good technical knowledge .. in that latest case it can be not as marvellous. It'd be me i'd put some safeguards and limits to what is possible to do (textures, mesh complexity, lighting ..), but it's not up to me.
Shadows are a notorious source of slow down in any 3D realtime application, (that mostly includes games of course). The difference being that in a standard game, the developers know in advance how they design a scene. (Yet there are examples of commercial games where the developer(s) obviously doesn't know about optimisations, including some AAA games).
This isn't true in SL. LL is providing a platform free to tweak for the "players".
So if we can't control how people design a place, we can still optimise the engine that is the viewer. That's what i try to do myself with my thin time resources. And other developers either in LL team or in 3rd party viewers, as the viewer is a collaborative open source project.
I am pretty sure shadows will come as a priority at some moment because it really has a severe performance penalty (in some places), and in the same time it really enhances the visuals. There are some techniques and tricks to optimise this.
Andred Darwin
observeur Resident
I somewhat have a different view than yours... there's a reason why SL simply cannot grow, and this just one small example of how confusing and general performance is perceived as horrible. I deal with similar experiences with users every day due to the store (add PBR / Reflection Probes, Env settings, etc... there you have a mess salad ).
All these tweaks / mobile app and all other great stuff will be useless to help SL, may help keep the current users, but until the UI is simplified and easier to use and performance is addressed, feel like its the same as wasting time and money.
We have been waiting for those to be addressed for a long, long time... SL gets what it deserves, unfortunately there is no way to escape that.
The priorities set by the team, from a user perspective, seems as out of touch as the majority of commits to the code, compared to the open issues, the steady decline since Covid has been at full swing, and will not be fixed or addressed any time soon.
Limits and warnings while building are needed to address performance and raise awareness in some cases, freedom of creation and miserable performance dont need to cross each other and or exist at the same time... can be managed and make SL as awesome as it can be.