//
// Generated by Microsoft (R) HLSL Shader Compiler 9.29.952.3111
//
// Parameters:
//
//   sampler2D Base;
//   sampler2D GBuffer1;
//   float4x3 global_FogPropertyMatrix;
//   float4 global_ViewPos;
//
//
// Registers:
//
//   Name                     Reg   Size
//   ------------------------ ----- ----
//   global_ViewPos           c214     1
//   global_FogPropertyMatrix c215     3
//   GBuffer1                 s0       1
//   Base                     s1       1
//

    ps_3_0
    def c0, 1, 0, 0, 0
    dcl_texcoord v0.xy  // In<4,5>
    dcl_texcoord2 v1.xyz  // In<6,7,8>
    dcl_2d s0
    dcl_2d s1

#line 37 "c:\Develop\LSProjects\build\shared\EyesOfAChild\Code\EoCApp\build\memory"
    texld r0, v0, s0  // ::depth<0>
    mad r0.y, r0.x, v1.y, c214.y  // ::WorldPos<1>
    mul r0.xzw, r0.x, v1.xyyz
    dp3 r0.x, r0.xzww, r0.xzww
    rsq r0.x, r0.x
    rcp r0.x, r0.x  // ::distance<0>

#line 29
    add r0.xz, -r0.x, c216.wyzw

#line 23
    add r0.y, r0.y, -c217.z
    rcp r0.w, c217.w
    mul r0.y, r0.w, r0.y  // ::heightDensity<0>

#line 29
    mov r1.zw, c216  // ::global_FogPropertyMatrix<7,10>
    add r1.xy, r1.wzzw, -c215.wzzw

#line 22
    rcp r0.w, r1.x

#line 29
    rcp r1.x, r1.y
    mul_sat r0.z, r0.z, r1.x  // ::ComputeDistanceFog<0>

#line 22
    mul_sat r0.x, r0.w, r0.x  // ::depthValue<0>
    max_sat r1.x, r0.x, r0.y  // ::ComputeHeightFog<0>

#line 36
    texld r2, v0, s1  // ::diffuseValues<0,1,2>

#line 46
    mov r3.x, c215.y
    mov r3.y, c216.y
    mov r3.z, c217.y
    lrp r0.xyw, r1.x, r2.xyzz, r3.xyzz  // ::Out<0,1,2>
    mov r1.x, c215.x
    mov r1.y, c216.x
    mov r1.z, c217.x
    add r0.xyw, r0, -r1.xyzz
    mad oC0.xyz, r0.z, r0.xyww, r1  // ::main<0,1,2>
    mov oC0.w, c0.x  // ::main<3>

// approximately 28 instruction slots used (2 texture, 26 arithmetic)
 