// // Generated by Microsoft (R) D3D Shader Disassembler // // // Input signature: // // Name Index Mask Register SysValue Format Used // -------------------- ----- ------ -------- -------- ------- ------ // TEXCOORD 0 xyzw 0 NONE float xyzw // TEXCOORD 1 xyzw 1 NONE float xyzw // TEXCOORD 2 xyzw 2 NONE float xyzw // TEXCOORD 3 xyzw 3 NONE float xyzw // TEXCOORD 4 xyzw 4 NONE float xyzw // TEXCOORD 5 xyzw 5 NONE float xyzw // // // Output signature: // // Name Index Mask Register SysValue Format Used // -------------------- ----- ------ -------- -------- ------- ------ // SV_Target 0 xyzw 0 TARGET float xyzw // ps_4_0 dcl_sampler s0, mode_default //SamplerState s0 {AddressU: CLAMP; AddressV: CLAMP; Filter: MIN_MAG_LINEAR_MIP_POINT}; dcl_resource_texture2d (float,float,float,float) t0 //Texture2D tex0; dcl_input_ps linear v0.xyzw //use all 6 vertex elements as input data and interpolate all of them linearly dcl_input_ps linear v1.xyzw dcl_input_ps linear v2.xyzw dcl_input_ps linear v3.xyzw dcl_input_ps linear v4.xyzw dcl_input_ps linear v5.xyzw dcl_output o0.xyzw //output 1 value with 4 channels dcl_temps 3 //float3 var0, var1, var2; 0: sample r0.xyzw, v0.zwzz, t0.xyzw, s0 1: mul r0.xyz, r0.xyzx, l(0.062500, 0.062500, 0.062500, 0.000000) //var0 = t0.Sample(s0, v0.zwz) * float3(0.062500, 0.062500, 0.062500); 2: sample r1.xyzw, v0.xyxx, t0.xyzw, s0 3: mad r0.xyz, r1.xyzx, l(0.031250, 0.031250, 0.031250, 0.000000), r0.xyzx //var0 += t0.Sample(s0, v0.xyx) * float3(0.031250, 0.031250, 0.031250); 4: sample r1.xyzw, v1.xyxx, t0.xyzw, s0 //var1 = t0.Sample(s0, v1.xyx); 5: mad r0.xyz, r1.xyzx, l(0.031250, 0.031250, 0.031250, 0.000000), r0.xyzx //var0 += var1 * float3(0.031250, 0.031250, 0.031250); 6: mad r0.xyz, r1.xyzx, l(0.062500, 0.062500, 0.062500, 0.000000), r0.xyzx //var0 += var1 * float3(0.062500, 0.062500, 0.062500); 7: sample r1.xyzw, v2.zwzz, t0.xyzw, s0 8: mad r0.xyz, r1.xyzx, l(0.125000, 0.125000, 0.125000, 0.000000), r0.xyzx //var0 += t0.Sample(s0, v2.zwz) * float3(0.125000, 0.125000, 0.125000); 9: sample r1.xyzw, v2.xyxx, t0.xyzw, s0 10: mad r0.xyz, r1.xyzx, l(0.062500, 0.062500, 0.062500, 0.000000), r0.xyzx //var0 += t0.Sample(s0, v2.xyx) * float3(0.062500, 0.062500, 0.062500); 11: sample r1.xyzw, v3.xyxx, t0.xyzw, s0 12: mad r0.xyz, r1.xyzx, l(0.031250, 0.031250, 0.031250, 0.000000), r0.xyzx //var0 += t0.Sample(s0, v3.xyx) * float3(0.031250, 0.031250, 0.031250); 13: sample r1.xyzw, v3.zwzz, t0.xyzw, s0 14: mad r0.xyz, r1.xyzx, l(0.062500, 0.062500, 0.062500, 0.000000), r0.xyzx //var0 += t0.Sample(s0, v3.zwz) * float3(0.062500, 0.062500, 0.062500); 15: sample r1.xyzw, v4.xyxx, t0.xyzw, s0 16: mad r0.xyz, r1.xyzx, l(0.031250, 0.031250, 0.031250, 0.000000), r0.xyzx //var0 += t0.Sample(s0, v4.xyx) * float3(0.031250, 0.031250, 0.031250); 17: sample r1.xyzw, v5.xyxx, t0.xyzw, s0 18: mul r1.xyz, r1.xyzx, l(0.125000, 0.125000, 0.125000, 0.000000) //var1 = t0.Sample(s0, v5.xyx) * float3(0.125000, 0.125000, 0.125000); 19: sample r2.xyzw, v4.zwzz, t0.xyzw, s0 20: mad r1.xyz, r2.xyzx, l(0.125000, 0.125000, 0.125000, 0.000000), r1.xyzx //var1 += t0.Sample(s0, v4.zwz) * float3(0.125000, 0.125000, 0.125000); 21: sample r2.xyzw, v5.zwzz, t0.xyzw, s0 22: mad r1.xyz, r2.xyzx, l(0.125000, 0.125000, 0.125000, 0.000000), r1.xyzx //var1 += t0.Sample(s0, v5.zwz) * float3(0.125000, 0.125000, 0.125000); 23: sample r2.xyzw, v1.zwzz, t0.xyzw, s0 24: mad r1.xyz, r2.xyzx, l(0.125000, 0.125000, 0.125000, 0.000000), r1.xyzx //var1 += t0.Sample(s0, v1.zwz) * float3(0.125000, 0.125000, 0.125000); 25: add o0.xyz, r0.xyzx, r1.xyzx 26: mov o0.w, l(1.000000) //Output = float4(var0 + var1, 1); 27: ret // Approximately 0 instruction slots used //rewritten code SamplerState sampler { AddressU: CLAMP; AddressV: CLAMP; Filter: MIN_MAG_LINEAR_MIP_POINT }; Texture2D texture; struct Input { float3 uv0 : TEXCOORD0; float3 uv1 : TEXCOORD1; float3 uv2 : TEXCOORD2; float3 uv3 : TEXCOORD3; float3 uv4 : TEXCOORD4; float3 uv5 : TEXCOORD5; }; float4 main(in Input In) : COLOR0 { float3 v = texture.Sample(sampler, In.uv0.xy) * float3(0.031250, 0.031250, 0.031250) + texture.Sample(sampler, In.uv0.zw) * float3(0.062500, 0.062500, 0.062500) + texture.Sample(sampler, In.uv1.xy) * float3(0.031250, 0.031250, 0.031250) + texture.Sample(sampler, In.uv1.xy) * float3(0.062500, 0.062500, 0.062500) //uv1.xyx is twice here, is this error? + texture.Sample(sampler, In.uv1.zw) * float3(0.125000, 0.125000, 0.125000) + texture.Sample(sampler, In.uv2.xy) * float3(0.062500, 0.062500, 0.062500) + texture.Sample(sampler, In.uv2.zw) * float3(0.125000, 0.125000, 0.125000) + texture.Sample(sampler, In.uv3.xy) * float3(0.031250, 0.031250, 0.031250) + texture.Sample(sampler, In.uv3.zw) * float3(0.062500, 0.062500, 0.062500) + texture.Sample(sampler, In.uv4.xy) * float3(0.031250, 0.031250, 0.031250) + texture.Sample(sampler, In.uv4.zw) * float3(0.125000, 0.125000, 0.125000) + texture.Sample(sampler, In.uv5.xy) * float3(0.125000, 0.125000, 0.125000) + texture.Sample(sampler, In.uv5.zw) * float3(0.125000, 0.125000, 0.125000); return float4(v, 1); }