On 30/08/2007, Stefan Dösinger stefandoesinger@gmx.at wrote:
The preferred way to do that is to use shader_glsl_get_sample_function().
Also note that previously the docs just said "The result is used to sample the texture at texture stage m by performing a 1D lookup." The addition of using 0.0 to extend the vector is apparently recent.
Am Freitag, 31. August 2007 09:35 schrieb H. Verbeet:
On 30/08/2007, Stefan Dösinger stefandoesinger@gmx.at wrote:
The preferred way to do that is to use shader_glsl_get_sample_function().
Yes, but additionally to the sampling function I needed the dimension of the vector cast, so I'd have needed a switch myself too.
On 31/08/2007, Stefan Dösinger stefandoesinger@gmx.at wrote:
Am Freitag, 31. August 2007 09:35 schrieb H. Verbeet:
On 30/08/2007, Stefan Dösinger stefandoesinger@gmx.at wrote:
The preferred way to do that is to use shader_glsl_get_sample_function().
Yes, but additionally to the sampling function I needed the dimension of the vector cast, so I'd have needed a switch myself too.
shader_glsl_get_sample_function() also gives you back a mask, which you can use to determine the size.