4
HLSL shader จริง ๆ แล้วมีผลกระทบต่อการแสดงผลอย่างไร
ฉันเข้าใจไวยากรณ์ของ HLSL เช่นสมมติว่าฉันมีสิ่งนี้เป็น HLSL ของฉัน: struct VOut { float4 position : SV_POSITION; float4 color : COLOR; }; VOut VShader(float4 position : POSITION, float4 color : COLOR) { VOut output; output.position = position; output.position.xy *= 0.7f; // "shrink" the vertex on the x and y axes output.color = color; return output; …