Game Development Community

Help with Low FPS

by addiktive · in Torque Game Engine Advanced · 03/05/2007 (11:15 am) · 7 replies

We are only at the very early stages of the project and have some of our own low poly models placed for testing along with a multi-tile atlas landscape.

We have discovered two unusual things.

Putting one model reduces FPS drastically and different systems are reporting different FPS results, but the differences are drastic.
One system had a FPS result of 0.4, another 11, and another 80. All systems are fairly similar, but we have encountered one pattern in the results.
Machines with Nvidia Graphics cards have a unplayable FPS compared with similar systems using ATI cards.

Since we are at the early stages of development, we are not too sure what to look for. Currently we are working on optimising our models, but what else can we do? At the current rate of FPS drops, we are not going to be able to build our game world.

The main problem is the Nvidia vs ATI results. Most likely something is not starting up correctly to take advantage of the Nvidia cards, but we don't know what that could be.

Any help/advice most welcome!

Edit: Also theres a ton of settings in the client > prefs.cs - Can any of these be 'tweaked' to get better performance?

Edit2: Does anyone have any 'world' optimization tips and techniques?

Edit3: We ran a series of tests using one of the Content Packs, with 7 DIF buildings placed, the 7 buildings sucked 40fps on their own, going from 80 down to 40, and these are from TAs content pack, so I assume they are optimized... This was on a Nvidia 7800gtx 512mb, 2.2ghz, 2gbRAM.... What concerns us more is the 'drop' in fps, more then the actual stable fps result...

#1
03/05/2007 (2:46 pm)
Since the atlas terrain basically doesnt cull anything, how do we go about culling or LODing waterblocks. We have several waterblock lakes etc that we need to either cull if they cant be seen or have a flat plane as a LOD variation...

The Waterblocks and DIF models are the major contributors to the fps drops, why the drop ratio is different between each machine is weird...

We have another thread where we would like to be able to cull atlas and objects seperately, so we can maintain the look of a large open world, while culling models earlier. We also need to be able to either cull waterblocks or at least script them to dynamically change like LOD, how much of this is possible, and is there anyone out there who is actually seriously trying to make a relatively large open world, experiencing similar issues..

Ultimately if we could have a long Terrain view distance, and shorter model view distance, and waterblocks that dynamically change from basic versions to the standard, we should be good... apart for the whole DIF building thing..
#2
03/05/2007 (3:49 pm)
While TA's buildings are pretty, they are far from what I'd call "optimized".

Are they technically correct? Absolutely.

Are they simply constructed from a performance standpoint? No. They have TONS of brushes. OK for an FPS, not exactly what I would implement in an MMO game.

Outdoor occlusion is the last great hurdle for TGEA to reach true maturity, IMHO.

Culling objects seperate from atlas requires zero code changes, unless you are trying to introduce an additional effect. To make your objects disappear at distance, create a Detail2 with no mesh attached. :) (in Milkshape you'll need to create a 0.1 unit wide 4 vertex object)

One important tip: immediate and substantial performance gains can be seen by turning off HDR and DRL. The effect is so expensive that it will quite literally cut your framerates down by over 40%. It's enabled on by default on the client, but you can turn it on and off via mission settings. Another super-hog is bloom, which is also on by default.

If you aren't planning on capitalizing on these features it's my suggestion to disable them completely. It's just not worth the performance hit for that extra bit of texture shading.
#3
03/05/2007 (4:00 pm)
Thanks for the reply Bryce, really our main downfall is the waterblocks and the lack of seperate model culling, buts whats a gameworld without lakes... :S What would be nice is if the Waterblocks could have a LOD version defined and be able to set the range at which it swaps.

My understanding was that DRL was essential for Day/Night transitions? So we would like to take advantage of that, unless we dont need to use it? HDR will be off, as it really doesnt add much to the scene for the cost. The game is primarily a Single Player RPG, rather than an MMO, but the gameworld is quite large at 32kmx32km.

I think once we manage to cull objects behind atlas terrain and come up with a way to LOD waterblocks we will be fine.

addikt
#4
03/05/2007 (9:08 pm)
Ok, we've come up with a solution for the Waterblock FPS Suckers...

We have created a flat plane .dts shape and applied the water shaders to it via the material.cs, now we replace all the lakes with this shape, effectively creating LODWater. Now all we need is a script that will swap that LODWater Shape for the proper WaterBlock when the player is within a certain range.. or hide and unhide etc..

We can look down the other end of the island with 6 LODLakes and get NO fps loss...

If anyone knows of a simple way to script this it would be much appreciated.. ;)

addikt
#5
03/05/2007 (11:03 pm)
Simplest would be to adapt the regular LoD code and instead of switching to different shapes, switch from waterblock to shader plane and back.
#6
03/06/2007 (11:53 am)
Awesome, thanks for taking the time to reply Marc. Im curious if anyone knows how to 'implement' Marcs solution?

Cheers

addikt
#7
03/08/2007 (12:31 pm)
Im surprised that more people arent experiecing issues with fps? I assume theres at least a few relatively large scale games in production using TGEA? Or is everyone pretty much only getting started?

Edit: Weve come across another issue with waterblocks is that they dont allow the foliage replicator to be viewed underwater when standing out of the water, hence our seaweed doesnt show up. Would that be a waterblock or foliage replicator change? (yes we have AllowonWater = on). It works when the player is underwater..

addikt