Hi.
I have doubts about what actually slows blendee down most.
Does the poly count affects most of or lights and materials ?
Also,normal and spec maps are "hungry "?
I am not sure what to optimize more,but i guess lighting.
Another thing is the alpha transparency, if i spawn a few planes with a smoke like texture with transparency the framerate really drops,and i can say i own a powerful video graphics card, why does alpha cost so much?
Polygons do slow the game down, but not as much as object batches - 4 1000 poly objects are slower than 1 4000 poly object. This is due to the batch rendering process. This means you should join any meshes that aren’t removed / added in game / have movement.
Next up; lights - costly at the moment, you’re better off using a few lamps but moving them around and changing settings. Use Lightmaps when you’re a distance away - you can’t tell the difference anyway.
Alpha; Using alpha sort or alpha blend is costly. Just use alpha clip where you can.
Normal maps aren’t that hungry unless they’re very high res. Normally 512 is all you’ll need for a decent look vs performance.
Ironic, just a few Minutes ago I also recognized how hungry Alpha Transparency is when I suggested mrn to use alphamapped Tris for his Swap-Tiles… but my Tests then resulted in the Fact that even twice the Polycount without Alphatransparency gave better Framerate. ô_Ô
I am not the Expert on the Topic, but Lights are most-probably the Heaviest.
Alpha clip reduces the transparency to transparent / not transparent, whereas the other two can have different grades of transparency AND z-sorting.
This is expensive, whilst having 1 / 0 (transp) is less so.
Ok.Thank you both for replyies.As expected…lights, also yes several objects tend to slow down the game, moerdn was talking about that in some threads, and i do join as many as possible.
Alpha sort, ok too bad looks bad.
And i forgot, 2 D filters are nice,too bad they are not that fast.
I must run several tests,if you got any other ideas on how to optimize please let me know.
ALSO I NOTICED UBUNTU INCREASES PERFORMANCE TO 20% , windows 50 / 55 frames in, some areas ubuntu always 60. I dont know what i did wrong tho, when i was disabling “use framerate” i was getting 120+ frames but now it wont work anymore,also the VBO in system settings not working anymore…(ubuntu) , works in windows tho.
Okay, just so there is no wrong Statement uncommented on this Thread: I have found out that the Problem I had confronted had nothing to do with the Transparency – it was the Size of the Polygons. It seems that the BGE does not like large scaled Triangles or at Least if the Triangles take too much Screenspace, which I do not really understand, but I have seen that earlier.
Easy to imagine:
As more pixels to fill on screen as more to process!
=> A small triangle is faster than a large triangle as it fills less pixels.
If you fill pixels with more small triangles it is slower than a few large triangles filling the same amount of pixels. Reasons there are more triangles to process.
Why does one object with joined meshes renders faster?
Each single object gets tested for visibility and other things before the triangles are rendered.
=> performing this processing for one object is faster than processing this with several objects.
BUT: objects outside of the camera frustum are skipped from render completely. This leaves the triangles of the remaining objects for render => less triangles = faster.
Joining objects can increasea framerate but another issue comes out, the possibility to use occlusion culing( which is important) cant help that much because of geometry, tho you can join small objects groups, like a group of small rocks,.but not objects that are spread all around the map.