cg片段 Cg程序片段写CGPROGRAM和ENDCG之间 开始时的片段可以作为#pragma语句编译指令 Pass { // ... the usual pass state setup ... CGPROGRAM // compilation directives for this snippet, e.g.: #pragma vertex vert #pragma fragment frag // the Cg/HLSL code itself ENDCG // ... the rest…
[Vertex and fragment programs] When you use vertex and fragment programs (the so called "programmable pipeline"), most of the hardcoded functionality ("fixed function pipeline") in the graphics hardware is switched off. For example, us…