Performance comparision
In Opengl es, I come to know two ways to do light effects, 1> using light map 2> using stencil buffers
Which is more ef开发者_开发技巧ficient way in term of performance comparision?
The answer is it depends. If you are heavily using stencilling, then your application may become fill rate limited. Doing a texture lookup on a light map can slow down your fragment/vertex shaders, also making your application fill rate limited. Generally though, light maps are more efficient, as they don't involve extra passes like most stencilling effects do. Moral of the story is, only bench marking will accuratly tell you what is more efficient.
精彩评论