Performance Expectation

Problems building or running the engine, queries about how to use features etc.
Post Reply
User avatar
Mr_Ridd
Goblin
Posts: 297
Joined: Fri Jun 04, 2004 10:01 pm
Location: South Africa
x 1
Contact:

Performance Expectation

Post by Mr_Ridd »

Hi guys

With the game a friend and I have developed, we seem to have performance issues, even though our scenes are not very involved, on lower end machines. And when I say lower end machines, I'm talking about an somewhat old, but decent GForce or ATI card. 1 Gig ram etc. So still decent.

A typical scene involves the following...

Max on-screen triangles : 3000
Meshes : 10
Materials: each mesh has its own material, and in that material are two passes, one for the diffuse, and one for a lightmap, and the same lightmap texture is used for all materials.
Lights: 1 point light
Shadows: stencil
Alpha: small amount of alpha
Particles: small amount, using FXExpression
GUI: MyGUI

The geometry is also very simple, so I can't see that the stencil shadows would affect it that much.

On my laptop, I have a decent ATI card, and I get about 45 FPS in release.

Any help or suggestions would be much appreciated, and what would you think the FPS should be.
The ability to succeed is the ability to adapt
kraj0t
Halfling
Posts: 89
Joined: Sun Mar 15, 2009 7:34 pm
Location: Seville (Spain)

Re: Performance Expectation

Post by kraj0t »

I'm not an expert in this matter, but this link from the wiki may help you.
User avatar
Mr_Ridd
Goblin
Posts: 297
Joined: Fri Jun 04, 2004 10:01 pm
Location: South Africa
x 1
Contact:

Re: Performance Expectation

Post by Mr_Ridd »

Thanks. Yeah I have already been through that article.
The ability to succeed is the ability to adapt
User avatar
Jabberwocky
OGRE Moderator
OGRE Moderator
Posts: 2819
Joined: Mon Mar 05, 2007 11:17 pm
Location: Canada
x 218
Contact:

Re: Performance Expectation

Post by Jabberwocky »

That does seem slow.
First question - do you have vsync on?
Second question - do the ogre samples run significantly faster?

A very simple approach to diagnosing your performance is to add the ability to shut off certain parts of your game. E.g. how fast is it if you don't draw the meshes? If you take out the particles? Or the shadows?
Image
User avatar
Mr_Ridd
Goblin
Posts: 297
Joined: Fri Jun 04, 2004 10:01 pm
Location: South Africa
x 1
Contact:

Re: Performance Expectation

Post by Mr_Ridd »

An update to this..

VSync is off.

The FPS from the samples is as follows, all in Release..

Character : 72 FPS
Lighting: 113 FPS
Ocean: 35 FPS
Particles: 60 FPS
Shader System : 65 FPS
Shadows: 22 FPS
Skybox: 108 FPS
Terrain: 17 FPS
Transparency: 70 FPS

.. with the following config..

System: D3D9
FSAA: No
Vsync: No
Res: 1360x780

I found something REALLY wierd though... with all libraries loaded, Ogre and MyGUI etc... I don't get more than 118 FPS when nothing is being drawn. I start my game, and just show a blank screen, and still the FPS sits around 118. I then took all my game code out and put timing outputs in, in milliseconds, from the FrameStart to the FrameEnd in my Ogre listener, and I got the following results...

This is very scary... why is it so jumpy? This is with no work done. No game code, and no render to screen.

Code: Select all

ms: 94
ms: 16
ms: 0
ms: 46
ms: 16
ms: 16
ms: 15
ms: 16
ms: 15
ms: 16
ms: 16
ms: 15
ms: 0
ms: 16
ms: 15
ms: 0
ms: 16
ms: 0
ms: 16
ms: 0
ms: 15
ms: 0
ms: 16
ms: 0
ms: 15
ms: 16
ms: 0
ms: 16
ms: 0
ms: 15
ms: 0
ms: 16
ms: 0
ms: 15
ms: 0
ms: 16
ms: 0
ms: 16
ms: 15
ms: 0
ms: 16
ms: 0
ms: 15
ms: 0
ms: 16
ms: 16
ms: 0
ms: 15
ms: 0
ms: 16
ms: 0
ms: 15
ms: 0
ms: 16
ms: 0
ms: 16
ms: 15
ms: 0
ms: 16
ms: 0
ms: 15
ms: 0
ms: 16
ms: 0
ms: 16
ms: 15
The ability to succeed is the ability to adapt
User avatar
Jabberwocky
OGRE Moderator
OGRE Moderator
Posts: 2819
Joined: Mon Mar 05, 2007 11:17 pm
Location: Canada
x 218
Contact:

Re: Performance Expectation

Post by Jabberwocky »

Based on the FPS you're getting with the ogre samples, it sounds like it's just a slow machine. For example, if the particles sample only gets 60 FPS, it's not surprising that your app is a little slower.

You can try lowering the resolution down from 1360x780. It might speed things up a little.

About the jumpy framerate - it's possible that number is lying to you. Maybe the timer on your machine doesn't have very good resolution, so anything below a certain amount of time gets reported as 0. How are you measuring the time? There might be a better, more accurate alternative.
Image
User avatar
Matheus Martino
Gremlin
Posts: 164
Joined: Mon Sep 07, 2009 10:44 pm
Location: Brazil
Contact:

Re: Performance Expectation

Post by Matheus Martino »

First, you did not say what is the configuration of that computers. Saying that you is using a Gforce or ATI means nothing (GForce 2? ... :roll:) .

I have a "lower end" machine hare, its processor is one Celeron 420 (a cheap single core remake of the Core 2 Duo that runs at 1,6Ghz) with 2GB of RAM.
Here the particles sample runs at 40 fps while using the Intel GMA 945 on-board gpu and at 300fps+ while using my Gforce 8600.
Excuse me if my english fail!
User avatar
altren
Gnome
Posts: 329
Joined: Tue Oct 24, 2006 9:02 am
Location: Moscow, Russa
x 24
Contact:

Re: Performance Expectation

Post by altren »

Mr.Ridd, I guess you are running on single core machines. Those "jumpy" timings are fine, because it depends on process scheduler. Sometimes it changes process between frameStart/frameEnd and sometimes not - that's simple.

And by the way, if you are running your app from visual studio it uses debug dlls (yes, in Release mode too). So you can also try to run it without debugging (Cltr + F5) or just run it from explorer. That might give you a bit higher FPS value.
Image
User avatar
Mr_Ridd
Goblin
Posts: 297
Joined: Fri Jun 04, 2004 10:01 pm
Location: South Africa
x 1
Contact:

Re: Performance Expectation

Post by Mr_Ridd »

Thanks for the comments.

Just some insight.... my laptop can run Call Of Duty: Modern Warfare very very well, and Torchlight also runs well. I'm just surprised that when nothing is drawn, it's still so slow.

Altren: Yeah you are right, I'll give it ago outside the debugger. But I can't see much improvement.

Matheus Martino: I'm not talking about crappy machines, but decent machines that guys run other games on without any problems.

Jabberwocky: All the timer is.... I get a tick count in the frame start and then compare it to the current tick count in the frame end... so i'm not really worried about less that 0 FPS... what concerns me is that is goes from 0 to 15/16 and so forth when no work is being done.
The ability to succeed is the ability to adapt
User avatar
Mr_Ridd
Goblin
Posts: 297
Joined: Fri Jun 04, 2004 10:01 pm
Location: South Africa
x 1
Contact:

Re: Performance Expectation

Post by Mr_Ridd »

Hey guys...

Any more thoughts/ideas around this? I stepped through Ogre's run loop, and it seems pretty simple, so I can't really see where the holdup is. Unless the GPU is doing something?
The ability to succeed is the ability to adapt
Post Reply