Page 1 of 3

more than 50% FPS speedup!!!! modified irrlicht 0.12

Posted: Thu Oct 27, 2005 11:08 pm
by Guest
speed increase result:
original = 275 fps
modified = 502 fps

both are the same scene (terrain, 200 nodes with simple cubes, 512x512 node texture, 256x256 terrain detail map, 128x128 terrain texture, everything is lit by one big dynamic light)

here are the changes which i have done:

- removed PSD support (not of any use)
- removed PCX support (not of any use)
- removed JPG support (i use tga instead, has alpha)
- removed PNG support (i use tga, has no external lib and licence)
- removed MD2 support (format depricated, .X file is best supported)
- removed MS3D support (milkshape sucks badly)
- removed LMTS support (no need for that)
- removed DMF support (no need for that either)
- removed My3D support (also no need for that)
- removed DirectX(8,9) support (does not work on linux, opengl is better IMHO)
- removed Software support (useless piece of code)

- added ackis extensions
http://irrlicht.sourceforge.net/phpBB2/ ... php?t=9380

- added Billboard culling fix
http://irrlicht.sourceforge.net/phpBB2/ ... php?t=7959

- added node-culling optimisations
http://irrlicht.sourceforge.net/phpBB2/ ... php?t=7959

- added vertex buffer objects for static meshes (meshes which do not have animations) (modified to work with irrlicht 0.12)
http://www.irrlichtnx.mmdevel.de/phpBB2 ... .php?t=210

- added anisotropic filtering (8x) :
http://irrlicht.sourceforge.net/phpBB2/ ... php?t=7964



so, even with 8x anisotropic filtering enabled the modified irrlicht version is still a lot faster (thanks to the VBO extension and node-culling/billboard fixes).

request: niko, it would be very nice if you could add a anisotropic filtering function to irrlicht, add the vertexbuffer objects extension for opengl and
add the billboard/node culling optimizations, that speeds up the engine a lot)


cheers!

Posted: Thu Oct 27, 2005 11:44 pm
by Maize
*Nice* work man! Thats awesome. Right now I am only using windows so I would have to keep dx8 in there. How long did it take you to do that?

Posted: Fri Oct 28, 2005 12:10 am
by Guest
you can use opengl with windows too, so that should be no problem.

no thanks to me, because i did nothing but implement the fixes from the irrlicht users (i included the links to their threads).

all toghether it took me an hour or so. i cannot upload the edited sourcefiles right now because i am not at home until sunday.

Posted: Fri Oct 28, 2005 2:00 am
by Guest
A zip of the patched files would be GREATLY appreciated for those of us just getting into the code.

If not, I'll go through the links and do it myself (of course), just slightly longer to the end result :)

Posted: Fri Oct 28, 2005 2:05 am
by Bryan Abrams
I like a lot of things you removed, but I liked using My3D alot.

Posted: Fri Oct 28, 2005 2:20 am
by Stu L Tissimus
Wow, impressive. Possible you could post the modified source for us to compile?

Also, as for the My3D removal, it shouldn't be that hard to add it back in. Hell, if we really felt like it, we could probably just make an ENABLE_MY3D variable or something.

Posted: Fri Oct 28, 2005 4:47 am
by Guest
i could upload the file sunday when im back at home.

my3d or any else loaders should be easy to get back in, just add the files to the project and change 1 or 2 lines i removed. i could do that

the changes do not have bugs for me at the moment, but maybe there are some "hidden" ones i dont see right now :D

just wanted to say that the original .dll has 1,48 mb and with the changes it has 587kb

Posted: Fri Oct 28, 2005 8:49 am
by Guest
I did a similar thing in my custom dll (~700k) but I left jpg in (along with PNG and TGA) and removed software renderer and DX9 (leaving OLG and DX8). WHy DX8? Because the target platforms I aim for are virtually guaranteed to have rubbish opengl support but still over robust DX8 drivers. That is fact. (researched). So on windows DX8 should be used as a priority if wide compat and speed are you goal. OGL is in there for a fallback - other platforms - of course OGL ;)

I put a few optimisations in (and some winstyle fixes that were bugging me like the contents of a window remaining black when another window passed over, no pausing on titlebar click and drag, close message intercept etc), but looking at your speed increase it looks like I'm going to have to go in again and so those other optimisations you mentioned!!

good work! :)

Posted: Fri Oct 28, 2005 2:18 pm
by WToma
Wow, it's just great that you did! Now may I hear some of those guys telling that Irr is slow :D
Toma

Posted: Fri Oct 28, 2005 2:41 pm
by Guest
another test:

1000 nodes (again, the same cubes) visible on the screen at the same time(!), each with fog and dynamic light enabled : 50fps (modified irrlicht).

with the original irrlicht, i guess i would have less than < 5 or 10 fps, so niko, could you _please_ add the modifications listed above add to irrlicht :) ? i beg you! :D

ps: i did not make the modifications (pr3ten3r, spintz, acki, disanti and Skiz0 did, all credits to them)

Posted: Fri Oct 28, 2005 6:52 pm
by Ishtm
I don't know how it works, all the things you removed do irrlicht render faster?
for example.... loaders are out of render loop, so how it can affect the performance? ...is because the dll keeps samller than the original?

Posted: Fri Oct 28, 2005 7:06 pm
by Guest
- added Billboard culling fix
http://irrlicht.sourceforge.net/phpBB2/ ... php?t=7959

- added node-culling optimisations
http://irrlicht.sourceforge.net/phpBB2/ ... php?t=7959

- added vertex buffer objects for static meshes (meshes which do not have animations) (modified to work with irrlicht 0.12)
http://www.irrlichtnx.mmdevel.de/phpBB2 ... .php?t=210
but these ones should. but i dont know if the fps is affected by the other stuff i removed, so i posted it, too.

Posted: Sat Oct 29, 2005 3:48 am
by Ishtm
very true, i read wrong your post, don't saw thats links.
So that percent is a lot!! and open infinite posibilities to irrlicht because
we can forget a little about performance care and dedicate it to something else.

you put the same links... can you write the url again?
GFXstyLER wrote:


because I heared sometimes things about Irrlicht in this forum wich can't be considerated building opinions... today i am puting a end line to the post. :)
________________________________________________________________________
Don't say Irrlicht can't do when you aren't doing

Posted: Sat Oct 29, 2005 9:47 am
by Andi|xng
Can anybody explain to me why removed support for some file formats increase speed? I can not really believe that... And if it is really true (because of less memory usage or so), I think it is only a very small FPS speedup.

MS3D is not a bad file format. IMHO MS3D is the best one, because .x has many bugs in Irrlicht.

I think your speedup is caused by the patches you included. Really nice work :)

Posted: Sat Oct 29, 2005 11:40 am
by Guest
but i dont know if the fps is affected by the other stuff i removed, so i posted it, too.
i mean that i removed that stuff for myself and then i "benchmarked" the modified engine. i dont know if they make a fps difference, so i posted them here, too :)

i also think they make no fps increase, but its nice that the filesize is only 1/3 of the original dll