2010年4月30日 星期五

Shader use register constant array index

Today I wonder if using register constant array index will influence performance. I design my experiment is a three point light shading shader:
  1. Lighting color, intensity, and position all them use three constant floating to set into shader separately.
  2. Use color, intensity, and position array, their size is three for shader computing.
In the experiment result, they all have the same frame rate are 2725. So in my experiment, using register constant array index doesn't has performance penalty.

沒有留言:

張貼留言