开发者

Performance comparision

开发者 https://www.devze.com 2023-04-06 08:34 出处:网络
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 d

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.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号