sampler2D vs sampler2DRect
Hello to everyone!
Sorry to be keep repeating but I keep finding a strange behavior inside the jitter shaders when I use sample2D. To exemplify the situation I 'translated' one of the quartz composer's examples using a wobble shader. The original version uses sampler2D, but when I use it inside jitter as it is, it doesn't work. However, when i add a sampler2DRect it seems to work, even though it doesn't behave as the original anymore.
Can some one explain the reason why sampler2D is not working in this shader?
Thank you very much
Emmanuel
if your source texture is square (ie. width = height), then you should use sampler2D and you should set the attribute @rect=0 on the gl.texture (it defaults to 1). if your source texture is rectangular, leave @rect alone, and use sampler2DRect in your shader.