|
2 registered members (Quad, AndrewAMD),
1,007
guests, and 6
spiders. |
|
Key:
Admin,
Global Mod,
Mod
|
|
|
Re: Optimize the Level
[Re: Pappenheimer]
#45468
05/10/05 12:16
05/10/05 12:16
|
Joined: Feb 2003
Posts: 6,818 Minot, North Dakota, USA
ulillillia
Senior Expert
|
Senior Expert
Joined: Feb 2003
Posts: 6,818
Minot, North Dakota, USA
|
Also, level geometry renders much slower than models. Try building only the walls that block from seeing large parts of the world as level geometry and have other objects as models.
Also, having lots of entities kills the frame rate as well so it's best to combine many models into one if at all possible. That's exactly what I'm doing. My city world, going even 25,000 quants from the center renders at even 30 fps or faster with the roads already laid out, the beach (which looks awesome and more comparable to other projects being made), and the water. Yet, I don't have portals being used! I ran an experiment and discovered many things that made this possible. I didn't, however, run the experiment with blocks (level geometry) and I should to see how it compares.
Also, if you have a lot of 1024x1024 textures (taking 2 megs of video memory each), you'll quite certainly run into problems when you have too many of these (different ones that is, using the same texture again and again makes almost no difference).
"You level up the fastest and easiest if you do things at your own level and no higher or lower" - useful tip
My 2D game - release on Jun 13th; My tutorials
|
|
|
Re: Optimize the Level
[Re: Gamesaint762]
#45470
05/11/05 04:14
05/11/05 04:14
|
Joined: Feb 2003
Posts: 6,818 Minot, North Dakota, USA
ulillillia
Senior Expert
|
Senior Expert
Joined: Feb 2003
Posts: 6,818
Minot, North Dakota, USA
|
Caution: avoid using 1024x768. A texture of this size will get stretched to 1024x1024 wasting memory. Resize your texture to either 1024x1024 or 1024x512. They have to be of a power of 2: 16, 32, 64, 128, 256, 512, 1024, 2048, 4096,....
"You level up the fastest and easiest if you do things at your own level and no higher or lower" - useful tip
My 2D game - release on Jun 13th; My tutorials
|
|
|
Re: Optimize the Level
[Re: ulillillia]
#45471
08/15/05 20:38
08/15/05 20:38
|
Joined: Nov 2003
Posts: 1,659 San Francisco
JetpackMonkey
Serious User
|
Serious User
Joined: Nov 2003
Posts: 1,659
San Francisco
|
Hi Ulillilililia Thanks for the great post! I am trying to optimize my level as well. You mentioned that things go a lot faster when you combine many models into one. By this, do you mean: 1. Group all your models together and create a map entity out of them? So that each model remains unique but they all live together within that map entity? or 2. Using Max or MED, merge the vertices and create one massive model file? Like using a boolean merge or something similar? Number 1 sounds good, though it doesn't intuitively seem that it would be faster.. and number two sounds difficult unless all the models are touching one another. Texturing would be especially tricky. and here's a 3rd question: Does anyone know a way to convert my WMB's (eg level geometry) into MDL's? Preferably complete with texture? THat would ROCK! Please, lemmeno  Thanks!
Last edited by Bonanza_Jellybean; 08/15/05 20:41.
|
|
|
Re: Optimize the Level
[Re: Excessus]
#45473
08/16/05 00:01
08/16/05 00:01
|
Joined: Feb 2003
Posts: 6,818 Minot, North Dakota, USA
ulillillia
Senior Expert
|
Senior Expert
Joined: Feb 2003
Posts: 6,818
Minot, North Dakota, USA
|
The thread I don't know about, but it's in my blog here. I have some new discoveries and I'd like to redo this experiment, especially on the high entity count part. Also, it'll include other types of entities as well - sprites and terrains in particular. Level geometry renders slowly as it is on almost any system so use it sparingly.
"You level up the fastest and easiest if you do things at your own level and no higher or lower" - useful tip
My 2D game - release on Jun 13th; My tutorials
|
|
|
Re: Optimize the Level
[Re: ulillillia]
#45474
08/16/05 01:17
08/16/05 01:17
|
Joined: Sep 2004
Posts: 260 UB,Mongolia
Olzii
Member
|
Member
Joined: Sep 2004
Posts: 260
UB,Mongolia
|
Hi ulillillia,
I need to optimize my level. Please help me. I'll give you credit.
The Empire of the Mongols comprised the largest continuous land empire ever, reaching from Korea to Poland
|
|
|
Re: Optimize the Level
[Re: Olzii]
#45475
08/16/05 08:03
08/16/05 08:03
|
Joined: Feb 2003
Posts: 6,818 Minot, North Dakota, USA
ulillillia
Senior Expert
|
Senior Expert
Joined: Feb 2003
Posts: 6,818
Minot, North Dakota, USA
|
I don't know true optimization, but these few things can help drastically: 1. Avoid level geometry - it renders slowly. Use it sparingly. 2. Make your levels as models instead. This can be tricky to do, but the reward is sheer speed. Having my entire city world in the view, I'm getting about 28 fps (if you eliminated the platforms) and I've got about 40,000 polygons visible at once. 3. For static things that don't change, use the my.dynamic in an action to further increase the frame rate. 4. Avoid having a lot of individual models that are the same thing (or slightly different) crowded up in one area. Have them all as a single entity. If there's a big gap of space between such related things, then you can use multiple entities and make use of the invisible flag to make the engine not render them. 5. Think about your level design and what you can and cannot see. You can make a rich-detail city using LOD at it's best. This isn't the type of LOD where you have multiple files of different detail levels, it's a type of LOD that, if something is otherwise invisible, turn the invisible flag off as otherwise, it'd be rendered. 6. For transparent things, avoid having them as part of the big model as it'll just waste disk space and video memory and could pose some other problems. Have the non-transparent parts as one single model and have the transparent things as a separate model. If only one degree of transparency is needed, don't use the alpha channel but write a small action to set the alpha (transparency) to what you'd like to get the same thing. Set the my.transparent flag to on first though. 7. Be creative. If your rooms have the exact same design, you only need one copy of that room - make use of positions and scripting them (and rotations) to give the illusion of an over-detailed world. They'll be hidden behind doors and walls anyway so the player can't see it. For a few thousand buildings, this can get tricky involving long scripts. Copy paste comes in handy for this. 8. Read the tips and tricks on my level creation tutorial for further details.
"You level up the fastest and easiest if you do things at your own level and no higher or lower" - useful tip
My 2D game - release on Jun 13th; My tutorials
|
|
|
|