2015年2月5日 星期四

shader

shader
https://processing.org/tutorials/pshader/

 On the other hand, the variables that change from vertex to vertex are called attributes, and in this example we have three different type of attributes per vertex: the xyz position itself, set with the vertex() function, the color specified with fill() and the normal vector. Note that even though there is only one call to the normal() function, each vertex will have its own normal vector, which in this case will be the same across the four vertices.







learn shader by example:
https://github.com/codeanticode/pshader-tutorials

=======================

opengl - shader
http://www.raywenderlich.com/70208/opengl-es-pixel-shaders-tutorial

Build and Share your best shader
https://www.shadertoy.com/