Cell preloading

General discussion regarding the OpenMW project.
For technical support, please use the Support subforum.
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: Cell preloading

Post by scrawl »

I take it the "ChangeCellGrid Took xx.xxx" messages are in milliseconds?
Yes, all the log statements use ms.

I wouldn't call it smooth yet, 100ms delay is still a noticable dip in framerate down to 10 fps, even if it only lasts a split second.

Just had the idea of using the preloader to speed up save game loading. While the main thread is parsing through the save game, use the background thread to preload the cell that the player will spawn in. That won't account for preloading objects that are only present in that savegame, but it probably doesn't matter. Currently the save game header doesn't include the cell that the player is in, only the name of the cell or the region's name. So it looks like I'll have to make a tweak to the save format first.
User avatar
lysol
Posts: 1513
Joined: 26 Mar 2013, 01:48
Location: Sweden

Re: Cell preloading

Post by lysol »

This is great. I love it when OpenMW gets exklusive features. And this feature rules.
User avatar
psi29a
Posts: 5361
Joined: 29 Sep 2011, 10:13
Location: Belgium
Gitlab profile: https://gitlab.com/psi29a/
Contact:

Re: Cell preloading

Post by psi29a »

Will this OSG features make it upstream?
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: Cell preloading

Post by scrawl »

Will this OSG features make it upstream?
Not sure what you mean. I haven't had to make any modifications to OSG for this feature.
User avatar
raevol
Posts: 3093
Joined: 07 Aug 2011, 01:12
Location: Caldera

Re: Cell preloading

Post by raevol »

scrawl wrote:I'm thinking about preloading fast travel destinations as well, though of course the downside is we don't know the travel destination the player will pick, so would have to load all of them preemptively.
Just my two cents, and I may be the only one who will ever think this, but I've always thought the fast travel was "too fast". Like I wouldn't mind if there was a one-second transition animation or effect that happened when you fast traveled, during which time the game could load stuff in the background. Just my opinion though...

Background loading for everything else sounds amazing though, I am super excited for it!
User avatar
psi29a
Posts: 5361
Joined: 29 Sep 2011, 10:13
Location: Belgium
Gitlab profile: https://gitlab.com/psi29a/
Contact:

Re: Cell preloading

Post by psi29a »

Ah super, I misread then, I thought this was taking advantage of OSG features in your fork.

So why hasn't this been merged in yet? :P
Antsan
Posts: 47
Joined: 13 Mar 2014, 11:15

Re: Cell preloading

Post by Antsan »

raevol wrote:
scrawl wrote:I'm thinking about preloading fast travel destinations as well, though of course the downside is we don't know the travel destination the player will pick, so would have to load all of them preemptively.
Just my two cents, and I may be the only one who will ever think this, but I've always thought the fast travel was "too fast". Like I wouldn't mind if there was a one-second transition animation or effect that happened when you fast traveled, during which time the game could load stuff in the background. Just my opinion though...

Background loading for everything else sounds amazing though, I am super excited for it!
There's a mod for that. I didn't ever try it, though.
User avatar
Lagahan
Posts: 47
Joined: 16 Aug 2014, 11:24
Location: Ireland

Re: Cell preloading

Post by Lagahan »

scrawl wrote: I wouldn't call it smooth yet, 100ms delay is still a noticable dip in framerate down to 10 fps, even if it only lasts a split second.
Yeah definitely, in most games I end up being absolutely anal about making sure my frametimes are a solid 8ms so i never drop from 120hz.
Still though I'm impressed that ye olde loading bar didn't pop up once even in the more object heavy cells, OpenMW-OSG is blowing the boots of blinding speed off of Vanilla now!
I'd imagine what I was doing in the video there was a bit OTT for the background loading to handle in any way smoothly and definitely isn't normal gameplay behavior.
Chris
Posts: 1626
Joined: 04 Sep 2011, 08:33

Re: Cell preloading

Post by Chris »

Antsan wrote:There's a mod for that. I didn't ever try it, though.
Ironically, that has the same problem, but from a different cause. Ultimately, the issue is the perceived world size. With instant fast travel, it makes the world feel small because it took no time to travel. Similarly, with actually traveling the distance, it shows just how close everything in the world actually is. Taking a few seconds with some kind of loading screen really seems to be the best way to go about it because it fools your brain into believing a good amount of time passed (the "Some time later..." effect), and you weren't seeing yourself go from A to B (which helps mask how short of a trip it actually was).

Instant travel could work for the mage teleports though, with an appropriate visual effect, since that's supposed to be pretty much instant.
User avatar
raevol
Posts: 3093
Joined: 07 Aug 2011, 01:12
Location: Caldera

Re: Cell preloading

Post by raevol »

Antsan wrote:There's a mod for that. I didn't ever try it, though.
I've seen that, I have to try it sometime! Is there one for boats?
Chris wrote:Similarly, with actually traveling the distance, it shows just how close everything in the world actually is.
Haha, interesting observation.
Post Reply