I’m trying to make the experience of loading our levels as smooth as possible in the Vive. Right now the best setup I’ve found is:
Loader map (contains nothing but our "level loading" BP) Sublevel - visuals Sublevel - effect Sublevel - backgrounds Sublevel - audio Sublevel - interactions
We have one of these for each unique area in the game (right now we’re at 5 or 6 of these). All the sublevels are set to be loaded via blueprint rather than always visible. The process of loading the levels is:
- GameInstance calls OpenLevel with the name of the loader map
- Level loading BP calls LoadStreamLevel (MakeVisibleOnLoad true, ShouldBlockOnLoad false) for each sublevel in order
Step 1 of this works more-or-less fine for now, it’s the second part which is having the problems.
As each sub-level is loaded, the SteamVR compositor rapidly fades in and out as the game misses frames due to loading times, and this is really ugly. We could fade the compositor in manually which might help with this, but part of the reason for having the level-loading BP is so that it can display some progress to let the user know things haven’t stalled.
We have this in our DefaultEngine.ini:
[/Script/Engine.StreamingSettings] s.AsyncLoadingTimeLimit=1.000000 s.PriorityAsyncLoadingExtraTime=0.000000 s.LevelStreamingActorsUpdateTimeLimit=1.000000 s.LevelStreamingComponentsRegistrationGranularity=1 s.AsyncLoadingUseFullTimeLimit=False
I’m really stuck with how to make this any better. The questions I have are:
- Is there any way to smooth this asynchronous loading to not interfere with the main thread?
- Is it possible to somehow stop the compositor flickering in/out when framerate drops?
- Can we render directly into the compositor so we can draw our loading progress there?
Maybe there are some other avenues for improvement which I also don’t know about, too. Any help is appreciated. I can also share some profiling files if that would be of any use.