Simply too many meshes...
Simply too many meshes...
OK, I accept that there will come a point at which my computer just can't render as fast as I want it to, but surely it can handle rendering 256 spheres?! When I put in that many I end up dropping down to about 15 fps. I have more faith in Irrlicht(and my computer) than that...
Is there any possible way of rendering 256 independent SceneNodes at a more reasonable rate? I shudder to think of how it would perform when I finish the game, where it might be required to render several thousand of them...
Is there any possible way of rendering 256 independent SceneNodes at a more reasonable rate? I shudder to think of how it would perform when I finish the game, where it might be required to render several thousand of them...
-
- Admin
- Posts: 3590
- Joined: Mon Oct 09, 2006 9:36 am
- Location: Scotland - gonnae no slag aff mah Engleesh
- Contact:
Have you tried running with release builds of Irrlicht and your app? There can be a huge difference in performance.
Also, are you doing anything other than just rendering spheres? Like, collision detection.
Also, are you doing anything other than just rendering spheres? Like, collision detection.
Please upload candidate patches to the tracker.
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
Need help now? IRC to #irrlicht on irc.freenode.net
How To Ask Questions The Smart Way
-
- Posts: 22
- Joined: Wed Jun 08, 2005 2:44 pm
Each sphere contains exactly 200 triangles, which, although it isn't quite as much as 1024, is still probably a hefty load for a graphics card as weak as mine. I've also tested all of the available options, and so far it seems like Direct3D9 works best.
Is my search for answers fruitless? Is there really no way to get around the lag?
Is my search for answers fruitless? Is there really no way to get around the lag?
-
- Posts: 1638
- Joined: Mon Apr 30, 2007 3:24 am
- Location: Montreal, CANADA
- Contact:
The quick thing to augment frame rate, is to use the fog and lower your camera depth level (FAR value of the view frustum). So the card won't have all theses spheres to render.
Also if they are really "rounds" as a sphere. A trick could be to use some billboards. (Would could perhaps need the extended billboard node). The only problem is that the spehere textures would not "rotate" depending of the angle of vision unless you do anothe programming trick.
Another thing would be to use LOD (Level of details). Calculate the distance from the camera to the object and replace it with variation of the sphere (EX: Very Far: Billboard, Far: A sphere with 60 tris, Near: Sphere with 200 tris,Very near: Spehre with 400 tris). You will have to replace each node at each frame (if your camera moved) with the LOD needed for that particuliar frame.
Also if they are really "rounds" as a sphere. A trick could be to use some billboards. (Would could perhaps need the extended billboard node). The only problem is that the spehere textures would not "rotate" depending of the angle of vision unless you do anothe programming trick.
Another thing would be to use LOD (Level of details). Calculate the distance from the camera to the object and replace it with variation of the sphere (EX: Very Far: Billboard, Far: A sphere with 60 tris, Near: Sphere with 200 tris,Very near: Spehre with 400 tris). You will have to replace each node at each frame (if your camera moved) with the LOD needed for that particuliar frame.
Although I don't have this problem this solution sounds very insightful. Maybe I'll use that in the near future so thanks.christianclavet wrote:The quick thing to augment frame rate, is to use the fog and lower your camera depth level (FAR value of the view frustum). So the card won't have all theses spheres to render.
Also if they are really "rounds" as a sphere. A trick could be to use some billboards. (Would could perhaps need the extended billboard node). The only problem is that the spehere textures would not "rotate" depending of the angle of vision unless you do anothe programming trick.
Another thing would be to use LOD (Level of details). Calculate the distance from the camera to the object and replace it with variation of the sphere (EX: Very Far: Billboard, Far: A sphere with 60 tris, Near: Sphere with 200 tris,Very near: Spehre with 400 tris). You will have to replace each node at each frame (if your camera moved) with the LOD needed for that particuliar frame.
he is right max sphere size is just 254x128 resulting in 32512 faces or 65024 polys which is not too much for modern cards. so just with that ( .irr file ) i get the same low FPS ..about 17.. while on the DEMO coming with irrlicht it shows a framerate of 70 with 600 polys. huge difference. ( nvidia 6600 here )
65000 Polys are rather a lot and I wouldn't be surprised if that's already slowing down a nvidia 6600. I have a 6200 and the FPS hit is always noticable here above 60000 polys.Mirror wrote:he is right max sphere size is just 254x128 resulting in 32512 faces or 65024 polys which is not too much for modern cards. ... ( nvidia 6600 here )
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
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
then how come that the Demo.exe has 500k polys and runs decently with 70+ FPS ?CuteAlien wrote:65000 Polys are rather a lot and I wouldn't be surprised if that's already slowing down a nvidia 6600. I have a 6200 and the FPS hit is always noticable here above 60000 polys.Mirror wrote:he is right max sphere size is just 254x128 resulting in 32512 faces or 65024 polys which is not too much for modern cards. ... ( nvidia 6600 here )
edit :
i have some ideas on how to implement LOD with meshes. if someone is interested i will elaborate.
Don't know. I just started the demo now for the first time and yes, seems you are right. I got the numbers from my own game which is using an older version - maybe Irrlicht got that much faster - or I used larger polygons, other lights, other materials, whatever. Polygoncounts are probably a bad unit for measuring speed anyway. I'm surprised that the demo has that many polygons.Mirror wrote:then how come that the Demo.exe has 500k polys and runs decently with 70+ FPS ?CuteAlien wrote:65000 Polys are rather a lot and I wouldn't be surprised if that's already slowing down a nvidia 6600. I have a 6200 and the FPS hit is always noticable here above 60000 polys.Mirror wrote:he is right max sphere size is just 254x128 resulting in 32512 faces or 65024 polys which is not too much for modern cards. ... ( nvidia 6600 here )
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
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
-
- Admin
- Posts: 14143
- Joined: Wed Apr 19, 2006 9:20 pm
- Location: Oldenburg(Oldb), Germany
- Contact:
IMHO the demo has 500k polys *per second*, which reduces to about 10k polys rendered per frame. And the demo has octree meshes, so even if the total polycount is much larger you do some efficient culling in there.
Oh, I have a discrete LOD scene node, but I'm not sure how to use it with arbitrary scene nodes and at the same time exposing all necessary interfaces (e.g. animatedmeshscenenode, billboardscenenode, etc.). I tested it with differently tesselated spheres, works pretty well.
Oh, I have a discrete LOD scene node, but I'm not sure how to use it with arbitrary scene nodes and at the same time exposing all necessary interfaces (e.g. animatedmeshscenenode, billboardscenenode, etc.). I tested it with differently tesselated spheres, works pretty well.