GLSL Texture Map types: Best and Worst on Frame Rate

How would you rank the following common GLSL map types in terms of their affect on frame rate?

  • Diffuse
  • Normal
  • Specular
  • AO (b+W image set to “color”, “multiply”)
  • Fake reflection (abstract image mapped to “Reflect”, “Color”)
  • Grunge/decals - Transparent BG PNG
  • Emit

I’d put specular at the top of the worst offender list. Diffuse is a must, AO can be combined with diffuse in some cases, but by itself has no affect, fake reflect? Decal - the GE has to work a bit harder to process the transparency.

Edit: Fake Reflection set up on two materials in a scene reduced frame rate by 1.5 frames per second when turned on. It must be the mapping - its dynamic, and changes with the view, as opposed to “UV” mapping, which is static. From a distance, the frame rate did not change. So, reflection maps affect frame rate when viewed close, as opposed to from a distance. Interesting.

Your thoughts?

Also, what is your opinion on the affect on frame rate of having many texture channels? What are some terrible combinations (e.g. 5 spec maps…).

Working on adding to my Game Speed Blog (see sig).

Specular is by far the worst next i would say normal and fake reflection seemed to have almost no hit for me.
i do not know how texture channels a affect me because i never have more than 4 because it is all I need.

  • Normal
  • Specular
  • Fake reflection (abstract image mapped to “Reflect”, “Color”)
  • Emit
  • Diffuse
  • AO (b+W image set to “color”, “multiply”)
  • Grunge/decals - Transparent BG PNG

Something like that, anyway.

use lamps with No Specular option, use only one specular lamp
use only one shadow lamp
dont use many lamps
move the lamps depending on the player’s position

multitexturing is a very fast thing on nowadays videocards, you can use 3-4 texture with various mappings, but must use simple blending modes (multiply, add, etc)

  • Normal
  • Specular
  • Fake reflection (abstract image mapped to “Reflect”, “Color”)
  • Emit
  • Diffuse
  • AO (b+W image set to “color”, “multiply”)
  • Grunge/decals - Transparent BG PNG

Something like that, anyway.

Worst to best I’m assuming here. Heaviest on the frame rate to lightest.

use lamps with No Specular option, use only one specular lamp
use only one shadow lamp
dont use many lamps
move the lamps depending on the player’s position

multitexturing is a very fast thing on nowadays videocards, you can use 3-4 texture with various mappings, but must use simple blending modes (multiply, add, etc)

Thanks. Yes, I have all that on my blog.

brilliant i had not thought of that one yet

@3D - Sorry, worst to best. Actually, grunge would be harder on the graphics card than diffuse. Diffuse would probably be at the bottom, since it’s just mixing (or multiplying) the color, but grunge would be transparent. So, it’s probably more like this (Worst to best):

  • Normal
  • Specular
  • Fake reflection (abstract image mapped to “Reflect”, “Color”)
  • Emit
  • Grunge/decals - Transparent BG PNG
  • AO (b+W image set to “color”, “multiply”)
  • Diffuse

Ok, great. I’ll add this to the frame rate blog, and Endi’s tip about moving lights around.

Double post to bump. Info added to the blog.

How about these assertions:

-Square textures perform best.
-Use nodes sparingly.
-Set gravity to 9.8 (default).

Anything else?

Edit: My python section disappeared! Damn. Solarlune - post those suggestions again, and your website. Thanks.

I think you must write an article about big engines. I think most of the Blender users can’t reach high framerates in big engines too…

probably not since most of them are noobs at game making and they build their games with no optimization at all.

I usually merge the Ao with the difuse texture since usually they have the same uv, you can do that with gimp or photoshop, just open the two images, put the dif image below the ao image and set the ao to multiply and its done, Its mutch better for the framerate!
Uhmmm, I agree with that but I keep working with the BGE! and looks like that our mates from this forum are starting to move some rocks in order to improve it, so probably I ll keep working on blender for somethime

I usually merge the Ao with the difuse texture since usually they have the same uv, you can do that with gimp or photoshop, just open the two images, put the dif image below the ao image and set the ao to multiply and its done, Its mutch better for the framerate!

Yes, but that’s not always an option. Tileable diffuse and textures for example on my castle walls. No way I can fit that into 1 texture. No need either.

I think you must write an article about big engines. I think most of the Blender users can’t reach high framerates in big engines too…

I know nothing about any game engine but Blender’s internal GE. So, I’m afraid I wouldn’t be qualified.

probably not since most of them are noobs at game making and they build their games with no optimization at all.

True, if rudely put sir. I started that blog post for that reason. No need to waste frame rates. Nobody can complain about frame rate now if they have not read that list and followed as many suggestions as possible (no, I’m not being immodest. My blog has been a collaborative effort; I have incorporated all the best ideas and suggestions I’ve found on the web and mostly here on BA).

i actually have read your GE speed blog and i would recommend it to blender GE users.
But i do not get the looping logic thing how do you do that.

Looping logic refers to using a single Python script to execute logic across multiple objects. This is how commercial game engines handle game objects-a single piece of code loops through all objects in a list, and updates and draws all objects in the list. You can achieve vast speed upgrades using this method. Of course, this requires a knowledge of Python.

that is just too bad because i do not enuph python two write a script I will have to read up on python now