Low FPS even when nothing is renderd on screen

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
manurung
Posts: 10
Joined: Mon Jun 11, 2012 2:38 pm

Low FPS even when nothing is renderd on screen

Post by manurung »

Hi All,

Right now I am working on a simulation for my university with several OBJ files and total 1166892 poly. As expected, the FPS goes to around 33 FPS.
But what is really strange, even when I move my camera to some an empty space with nothing on it to render/display, I still have the same 33 FPS.

I used OGRE before, it only rendered thing it displayed. For instance, when I move my camera to a less complex structure, the FPS will increase, and vice versa.
The other way around, Irrlicht's FPS is always constant.

Where did I do something wrong?
Is there any parameter should be set to get this kind of behavior?

-- Auralius
Bl00drav3n
Posts: 48
Joined: Sun Apr 22, 2012 11:55 pm
Location: Vienna
Contact:

Re: Low FPS even when nothing is renderd on screen

Post by Bl00drav3n »

How do you create your objects?
CuteAlien
Admin
Posts: 9670
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Low FPS even when nothing is renderd on screen

Post by CuteAlien »

You can influence culling per scenenode with setAutomaticCulling:
http://irrlicht.sourceforge.net/docu/cl ... d2db28c5b8
That decides which nodes will be tranfered to the graphic-card.

You can also use more advanced clipping for static scenes by using an Octree.

Also you can avoid regular uploading to the graphiccard for static (non changing) meshes (the nodes can still move, scale etc) by calling setHardwareMappingHint with EHM_STATIC: http://irrlicht.sourceforge.net/docu/cl ... 8599043dfe
That way only the graphiccard will do clipping (which is often faster than any culling on the CPU side).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
manurung
Posts: 10
Joined: Mon Jun 11, 2012 2:38 pm

Re: Low FPS even when nothing is renderd on screen

Post by manurung »

Thanks for quick reply.

@ Bl00drav3n:
I load my object using the standard way as in Hello World tutorial:

Code: Select all

 
nds->bed_node =   smgr->addOctreeSceneNode(smgr->getMesh( "../model/bed_structure.obj"));
 
Of course, I have like 10 of these objects. They have certain hierarchy, like one node is a child of another node and so on.

@CuteAlien:
I will have a look and try your suggestion. I will come back again. 8)
manurung
Posts: 10
Joined: Mon Jun 11, 2012 2:38 pm

Re: Low FPS even when nothing is renderd on screen

Post by manurung »

I tried all suggestions from CuteAlien, but nothing works.

I checked PerPixelLighting demo, it works just like the way I mentioned earlier, when I go to outer empty spaces, the FPS increased.
But it does not happen to me. I saw that there were no special variables/parameters tuned to get this kind of behavior.

Now I am really confused.
hendu
Posts: 2600
Joined: Sat Dec 18, 2010 12:53 pm

Re: Low FPS even when nothing is renderd on screen

Post by hendu »

The default is bounding box. So if you're inside a big box, even if you can't see the big box, the big box is drawn.
nespa
Posts: 167
Joined: Wed Feb 24, 2010 12:02 pm

Re: Low FPS even when nothing is renderd on screen

Post by nespa »

try with vsync false to see the limits fps, then you will find the solution
manurung
Posts: 10
Joined: Mon Jun 11, 2012 2:38 pm

Re: Low FPS even when nothing is renderd on screen

Post by manurung »

Thanks for replying.

I do disable the vsync .

And I tried to find out more about bounding box, I checked CostumizedSecenNode example that came with Irrlicht package. It seemed that bounding box is a box that is sorounding a scene node around its origin point.

So, in my case, I have several scene nodes. So do I need to create a costumized scene node for each node that I have and define its bounding box. Which bounding box will be the main player here? The biggest one?

CostumizedSceneNode in example folder has only one node there, so it's easy to grasp the idea, but now I have several nodes here.
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Re: Low FPS even when nothing is renderd on screen

Post by hybrid »

You cannot mix octree scene node and EHM_STATIC. At least IIRC, the default octree setup uses an incompatible mesh buffer structure. Try to load just with getMesh and set the static usage afterwards. Also try to visualize the bboxes in case you assume errors.
Post Reply