glsl: Add textureSize(*samplerBuffer) support.

Fixes the corresponding new tests in piglit.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Eric Anholt 2012-04-12 16:28:37 -07:00
parent 9a01e09ee5
commit d91c8edd85
3 changed files with 9 additions and 0 deletions

View File

@ -504,6 +504,10 @@ ivec2 textureSize(isampler2DRect sampler);
ivec2 textureSize(usampler2DRect sampler);
ivec2 textureSize(sampler2DRectShadow sampler);
int textureSize( samplerBuffer sampler);
int textureSize(isamplerBuffer sampler);
int textureSize(usamplerBuffer sampler);
/* texture - no bias */
vec4 texture( sampler1D sampler, float P);
ivec4 texture(isampler1D sampler, float P);

View File

@ -504,6 +504,10 @@ ivec2 textureSize(isampler2DRect sampler);
ivec2 textureSize(usampler2DRect sampler);
ivec2 textureSize(sampler2DRectShadow sampler);
int textureSize( samplerBuffer sampler);
int textureSize(isamplerBuffer sampler);
int textureSize(usamplerBuffer sampler);
/* texture */
vec4 texture( sampler1D sampler, float P);
ivec4 texture(isampler1D sampler, float P);

View File

@ -162,6 +162,7 @@ def generate_texture_functions(fs):
generate_sigs("", "txs", "2DArrayShadow")
generate_fiu_sigs("txs", "2DRect")
generate_sigs("", "txs", "2DRectShadow")
generate_fiu_sigs("txs", "Buffer")
end_function(fs, "textureSize")
start_function("texture")