OpenGL (2D) advancement

I’ve worked on moving to OpenGL instead of software rendering lately, it’s a big work, but I made great progress.

At the moment Snorms is fully software rendered (no¬†OpenGL or acceleration of any kind, I’m not even using Java2D), so it’s using a lot more CPU than GPU. Moving to OpenGL will improve performance as CPU will less be used for graphical stuffs. And I hope that if performance gain is high enough I will be able to swtich from 30fps to 60fps by default.

I am using Slick2D to do all this 2d OpenGL stuff, it’s a great library, I should have used it from the beginning, it would have made development a lot faster. It might also help porting ICE (Isometric Cube Engine, the engine used by snorms, the level editor, and the old snake game “kleum”) to android, if I want to make an isometric game on this platform (nothing planned yet, but I might give it a try)

I don’t know when this version will be published, there are still lot of work to do, and I don’t have a lot of time…

Currently on my computer I can get around 200 fps while playing, with software rendering I can barely get to 60. Everything is not supported yet (alpha blending, color replacement and other software rendered effects I was using have not been replaced) but graphical result is still quite correct for a first try, I’m quite happy with this (and I didn’t except to get 200 fps on the first try).

Of course engines are still 30 fps, so it’s no use yet, I think I will just switch the particle engine to 60 (or maybe dynamic) fps, other engines will remain at 30 fps (I don’t need monsters or lights to be updated more than 30 times per second for example). It really makes a difference, especially for quick bullets (pistol, shotgun and such).

Comments are closed.