Quantcast
Viewing all articles
Browse latest Browse all 40524

Varying vec2 surfacePosition

Hi,
no, the varying passes a value from the vertex shader to its correspondent fragment shader.
Using varyings you can pass whatever you want between the vert and frag shader.
As of the surfacePosition, out of a quick look at it in glslsandbox, it just seems to contains the screen coordinates for each vertex. There might be also some issues whether it is using normalized or not values.
If you want to use glslsandbox shaders right away with OF, you should try @patricio 's superb ofxFX addon. https://github.com/patriciogonzalezvivo/ofxFX
Best


Viewing all articles
Browse latest Browse all 40524

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>