摘要:
自http://nehe.gamedev.net/article/glsl_an_introduction/25007/一、一个最简单的着色器程序Ambient Shader, 所有的像素点都渲染为一种指定的颜色Vertex Shader1 void main() 2 { 3 // Transforming The Vertex 4 gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex; 5 }Fragment Shader1 Void main() 2 { 3 // Setting Each Pixel To R... 阅读全文