Page 1 of 1

Maintaining Speed

Posted: Sun Jan 09, 2005 2:01 pm
by Mr_Ridd
Hey

I have a slight issue and I'm not sure if it's OGRE or if I'm doing something wrong. I made a model of a picket fence ( a section ) which is about 200 polys. If I add about 10 to 15 of these fences I get a big lag. If you do the math it's only about 3000 polys plus the heightmap. How do games like Half-Life 2 and Medal Of Honour Pacific Assault maintain their framerate, bearing in mind they have effects and all different things going on at the same time?

Thanks

Posted: Sun Jan 09, 2005 4:38 pm
by sinbad
Well, aside from the whole 'batching' discussion which has been had many times already on this forum, are you sure it's even Ogre? I have a test case here which renders lots of entities at once:
Image

That's 400 Ogre heads in the scene (not all visible at once), each one is 4500 polys at full detail, LOD to a minimum of about 1000 at very far distance - that shot has a total of over 100,000 polys. Each one is 4 render operations too. Still I get 150-200fps.

So I can't understand why you're saying you get such big lags. Are you sure you're not doing something whic is causing it?

Posted: Sun Jan 09, 2005 5:28 pm
by Mr_Ridd
I really don't know how you do that. If I add like 5 ninjas it lags. Perhaps because I have a terrain and I'm keeping all objects above the terrain with ray casting collision. But that shouldn't make it lag. Even other demos I've seen, like the racing one, they have quite a lot of things in the scene and I presume they get a decent frame rate.

Posted: Sun Jan 09, 2005 8:40 pm
by stodge
Do you have any profiling tools you can run on your code?

Posted: Sun Jan 09, 2005 8:46 pm
by Kencho
Maybe the problem is performing ray collision for every object...
Also, I've had serious lag problems caused by writing to disk with logging. Another possibility is that you're runinng on debug mode...

Posted: Mon Jan 10, 2005 8:40 am
by epopov
Also, maybe your fences use textures with alpha and are displayed big on screen ?