Go Back   Epic Games Forums > Unreal Tournament 3 > User Maps & Mods

Reply
 
Thread Tools Display Modes
Old 12-03-2007, 02:48 AM   #1
evilmrfrank
Senior Member
 
evilmrfrank's Avatar
 
Join Date: Jul 2006
Posts: 237
Default Optimizing for UT3

Ive written a quick tutorial for optimizing your maps for UT3. This isn't really a how to do, but more of a what to what to do tutorial. Also this tutorial doesn't really cover older things that you could do for UT2004 a whole lot, mostly what's new with UE3. Although the tutorial is mostly finished there are a few things that I have left out which will be added in the coming day or two.

http://www.evilmrfrank.com/Optimizing.htm
__________________
www.evilmrfrank.com
-----------------------

Last edited by evilmrfrank; 03-04-2008 at 11:44 AM.
evilmrfrank is offline   Reply With Quote
Old 12-03-2007, 05:28 PM   #2
-=¤willhaven¤=-
Super Moderator
 
-=¤willhaven¤=-'s Avatar
 
Join Date: May 2000
Posts: 2,107
Default

A few caveats.

Remove Surface Material is only useful in instances where you absolutely do not want that BSP to help occlusion. So, using it on the undersides and edges of additive BSP used for floors is probably OK, taking out the whole side of an additive BSP building which contains more meshes, probably not a good idea.

I generally find BSP that I can optimize or make black and set it to default texture so I can easily select them all at once and re-do the 65536 lightmap and uncheck all the lighting options.

In regards to BSP lightmaps, you're pretty much spot on, except sometimes we go as high as 256 or 1024 even in areas where you can get close to the surface. Sometimes they're lit so flatly that you can make the lightmap really blobby and you won't notice the difference.

I generally start by setting all of the BSP in the map to 8 and rebuild to see what shadows I feel are important, then I save them to the selection, set the others low and just pump up the detail on the important surfaces.

On Cull Distance. Now we have Cull Distance volumes to specify what sizes of meshes in that particular area get culled at what distance. You don't have to do it manually mesh-by-mesh anymore.

On Terrain. Be weary of large lightmaps on terrain. Unlike BSP, a higher number = better terrain lightmap resolution. So, a setting of 16 on a large terrain would be ridiculous.

On Blocking Volumes, I've never found them to be much of a drain (either in terms of performance or memory) in comparison to things like greedy lightmap usage or leaving unnecessary meshes with ragdoll collision enabled, etc.

One addition I think would be helpful...

You can lightmap static mesh actors that have a proper 2nd UV channel. Many of the meshes in the game have usable 2nd UV channels for lightmapping, but some do not. You can get HUGE overall memory savings by swapping away from vertex lit meshes to using small lightmaps (16x16 or 32x32). This is located in the StaticMeshComponent dropdown under OverriddenLightMapResolution.

The tradeoff is that the lightmaps generated get added to the texture pool. So, doing this too much on a console system would add unnecessary overhead and limit your ability to stream in textures to their full detail level. If your level has some excess texture space and you want to hack the file size down considerably, doing a lightmapping pass on static meshes in the level will do wonders.

If you open the generic browser and go to the Primitive Stats tab, you can sort by Lightmap (KByte) to get a feel for how much vertex memory is taking up in your levels. It's not uncommon for a mesh to be used 100 times or more in a level, and if the mesh has a lot of verts, if often ends up taking more than 1mb worth of vertex lighting data to light that mesh across the entire level. I generally start by getting all lightmap usage under 1mb then I re-cook and see if it fits in memory. If not, I'll to go 500k, then 100K. Sometimes getting a mesh that low isn't possible, but you do it where you can.

If you double click on the worst offenders, you can select them all and set an appropriate lightmap size. A 32x32 lightmap starts to become an attractive option on meshes of 1000 verts or more.

You can check the mesh to see if it will take well to lightmapping by selecting it, right clicking and doing a "sync in generic browser," opening the mesh viewer, and clicking to show the 2nd UV channel. You can usually tell by looking at it whether or not it's set up for lightmaps or not.

It's usually a good idea to apply the lightmaps to all the meshes and rebuild lighting to make sure it still looks ok afterward.

WAR-Powersurge is a good example of a map that's been lightmapped into oblivion.

Sorry, this is probably a bit long winded and random since I didn't really proofread this, but I hope it adds a bit for you. Cool tutorials by the way, it's good to see people willing to step up and help the community.
__________________
"I are serious developer. This is serious post."
Phil Cole
Pixel Pusher
Epic Games

Last edited by -=¤willhaven¤=-; 12-03-2007 at 05:32 PM.
-=¤willhaven¤=- is offline   Reply With Quote
Old 12-03-2007, 06:19 PM   #3
evilmrfrank
Senior Member
 
evilmrfrank's Avatar
 
Join Date: Jul 2006
Posts: 237
Default

Ah I learned a lot from reading your post The thing you posted on the remove surface feature I didn't know. That is pretty important. Also I didn't really write anything about the static mesh lightmaps so that is something else I need to add And your right blocking volumes aren't that bad on performance but they are worse than using a mesh plane to block stuff off It appears I have a bit more retouching to my tutorial than I thought :P I wrote it off the top of my head so I knew there were things I was forgetting. Also forgot the clean bsp surfaces

Thanks for the tips, I will make the changes when I can
__________________
www.evilmrfrank.com
-----------------------
evilmrfrank is offline   Reply With Quote
Old 12-26-2007, 02:59 PM   #4
MeepZero
Senior Member
 
MeepZero's Avatar
 
Join Date: Sep 2007
Posts: 263
Send a message via AIM to MeepZero
Default

So I'm assuming that the lightmaps set at 8 are very low resolution while upping it up to something like 32X32 is "high" resolution?

How big of a deal is this for PC version users? I'm guessing by the amount of RAM talk here that this is primarily for PS3 users.
__________________
Dogs of War | Zero Frag Community
MeepZero is offline   Reply With Quote
Old 02-20-2008, 05:34 PM   #5
evilmrfrank
Senior Member
 
evilmrfrank's Avatar
 
Join Date: Jul 2006
Posts: 237
Default

When talking memory most of the things can be taken into account for both PS3, and PC. Probably most important on the PS3 though since it actually has a limit. PC basically just to keep load times down and download size lower for servers. 32X32 is a high resolution for a terrain. Lower numbers for the terrain = lower quality lightmaps. Lower numbers for bsp surfaces = higher quality lightmaps.
__________________
www.evilmrfrank.com
-----------------------
evilmrfrank is offline   Reply With Quote
Old 02-20-2008, 06:13 PM   #6
Alex D
Senior Member
 
Join Date: Nov 2007
Posts: 157
Default

A note regarding the presentation of the article, it would be far easier to read if you got rid of the rather annoyingly small iframe and allowed it to expand to the height of the user's browser.
Alex D is offline   Reply With Quote
Old 02-24-2008, 12:56 PM   #7
GUPraeToriaN
Senior Member
 
Join Date: Sep 2007
Posts: 124
Default

i may be a little dumb for asking this question but,how do i set meshes to 32x32 or 16x16 and how do i set them under 1 MB?


/edit

ok i found out how to do the 16x16 stuff but i still need to know how to get them under the 1 MB mark

Last edited by GUPraeToriaN; 02-25-2008 at 01:06 AM.
GUPraeToriaN is offline   Reply With Quote
Old 02-26-2008, 03:50 PM   #8
evilmrfrank
Senior Member
 
evilmrfrank's Avatar
 
Join Date: Jul 2006
Posts: 237
Default

There is no set way to get it to 1MB You just have to change the res on it and keep your eye on the lightmap area under the primitive stats browser for your mesh.
__________________
www.evilmrfrank.com
-----------------------
evilmrfrank is offline   Reply With Quote
Old 02-26-2008, 08:21 PM   #9
GUPraeToriaN
Senior Member
 
Join Date: Sep 2007
Posts: 124
Default

cool thx..now for one last question...i want to add some anti-portals in my map...i can't seem to find them anywhere, did epic keep them or did they get rid of them?
GUPraeToriaN is offline   Reply With Quote
Old 02-26-2008, 09:07 PM   #10
Kyben
Senior Member
 
Kyben's Avatar
 
Join Date: Nov 2007
Location: Florida, USA
Posts: 145
Default

A friend showed me your optimization tips a long time ago at http://evilmrfrank.com/Optimizing.html. I was afraid you took it down and weren't going to put it back up. Thanks for putting it up again. It helped me out alot back then, and it can help me out now.
__________________
Black Sierra Dev.
Kyben is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Video Game Voters Network
 
All times are GMT -4. The time now is 12:16 PM.


Powered by vBulletin
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Copyright ©2009-2010 Epic Games, Inc. All Rights Reserved.