Discussion for March update

New releases and general discussions.

Post » Thu Mar 05, 2009 4:33 pm

I think it should have a few ways of going about it.

1. Load everything at start, like it is now. A lot of games are small enough that pretty much any card could load them, and then you don't have any loading issues.

2. Upon going from one layout to another, dump everything except global objects and load all objects on the new layout into VRAM.

3. Have a checkbox "keep in VRAM" - like for the main character, who's going to be used often, even if they're not global. Can be overridden by:

4. Manual controls. Example: At start of layout, dump everything (except the stuff in #3), delete the objects you don't want to use, then use a "load objects in layout" command. Or the "destroy at startup" attribute will prevent an object from being loaded into VRAM.

There might be a better way of going about it, but those're my thoughts.
Moderator
B
88
S
32
G
33
Posts: 3,005
Reputation: 27,432

Post » Thu Mar 05, 2009 6:58 pm

Can't that somehow be streamed? I mean, always load the current layout and always already start streaming the previous and the next layout into the vram - and kick out everything else.

I'm sure I'm uber-simplifying it, but isn't that how it's usually being done?
B
6
S
2
G
3
Posts: 520
Reputation: 2,690

Post » Thu Mar 05, 2009 10:18 pm

[quote="thomasmahler":fqzgo3p3]Can't that somehow be streamed? I mean, always load the current layout and always already start streaming the previous and the next layout into the vram - and kick out everything else.[/quote:fqzgo3p3]
If you jump to a layout that's not the next, you'd get choppyness.

That said, it would be cool to hint a preload.
Like an action: load layout x into VRAM

you could trigger it with enough time and if there's not enough time, well, choppyness. :)
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Thu Mar 05, 2009 10:46 pm

So what happens right now is that the whole game is loaded into the vram at start, right? Couldn't we just create triggers that'd tell the engine to start streaming what we'd need? Like, it's not too hard to imagine that if you're on layout 2 and got 10 layouts, you probably won't be able to go to more than 3 layouts next. You either go to layout 1, layout 3 or you go to the menu. We could set triggers for that. If player is on layout 2, start streaming layout 2 and 3.

Or: If player overlaps with 'StreamObject', start streaming layout 3.

We could have the menu screen as a global layout always in the ram.

In the case of that not being enough, we could still simply create a "Now Loading" layout that the engine automatically temporarily jumps to when changing layouts.

Again, I'm pretty sure I'm really oversimplifying it, but maybe some input from how a lowly artist sees it will help :)
B
6
S
2
G
3
Posts: 520
Reputation: 2,690

Post » Thu Mar 05, 2009 11:13 pm

Hmm, streaming. Could we potentially load things into VRAM without it pausing, if what's being loaded isn't needed yet? So instead of putting the texture through immediately, it would work like this:

CPU runs events
GPU renders frame
Load textures in time between frames

If it's time to render the next frame and the texture hasn't finished loading, wait for the cpu and gpu to run again before loading the rest of it.

Don't know if it's possible or not, but it would help a lot to keep gameplay smooth and reduce loading times.
Moderator
B
88
S
32
G
33
Posts: 3,005
Reputation: 27,432

Post » Fri Mar 06, 2009 12:45 am

I don't think streaming is possible in DirectX. Both the CPU and GPU wait until the texture upload completes, and that is almost certainly a noticable pause.
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,630

Post » Sun Mar 08, 2009 6:35 pm

Well you can also use a loading screen while using the vram controls for really large projects right?

I also hope in the next build you include this feature suggestion -> viewtopic.php?f=17&t=3026
B
3
S
2
G
5
Posts: 301
Reputation: 2,302

Post » Wed Mar 11, 2009 3:41 am

[quote="liamdawe":1gavfun9]Well you can also use a loading screen while using the vram controls for really large projects right?[/quote:1gavfun9]
you could have a loading screen layout that loads real quick, then once inside of it you load the next layout.
B
3
S
2
G
4
Posts: 1,445
Reputation: 4,665

Post » Sat Mar 14, 2009 8:27 am

[quote="Arima":1yzxtvyz]I think it should have a few ways of going about it.

1. Load everything at start, like it is now. A lot of games are small enough that pretty much any card could load them, and then you don't have any loading issues.

2. Upon going from one layout to another, dump everything except global objects and load all objects on the new layout into VRAM.

3. Have a checkbox "keep in VRAM" - like for the main character, who's going to be used often, even if they're not global. Can be overridden by:

4. Manual controls. Example: At start of layout, dump everything (except the stuff in #3), delete the objects you don't want to use, then use a "load objects in layout" command. Or the "destroy at startup" attribute will prevent an object from being loaded into VRAM.

There might be a better way of going about it, but those're my thoughts.[/quote:1yzxtvyz]

yes, yes, all that

but the checkbox "keep in VRAM" should be toggle-able at runtime, so you can easily exclude one or two things from the dump, and decide that at each level.
Spriter Dev
B
88
S
21
G
12
Posts: 3,240
Reputation: 16,486

Post » Mon Mar 16, 2009 4:04 pm

just curious... will we now have to specify everything we want to load in vram or will it load everything by default, as it is currently? small games dont require that level of control and im wondering if the added control will increase the time it takes to slap something together. Im almost certain it will be as is by default. am i wrong? (forgive me if i missed something mentioned above, didn't read everything word for word)
B
25
S
3
G
6
Posts: 1,197
Reputation: 5,620

PreviousNext

Return to Construct Classic Discussion

Who is online

Users browsing this forum: No registered users and 3 guests