//Specular VS 1.
//
// Generated by Microsoft (R) D3DX9 Shader Compiler 
//
// Parameters:
//
//   float4 gCameraPos;
//   float gFogDensity;
//   float gFogEnd;
//   float gFogStart;
//   int gFogType;
//   row_major float4x4 gLocalToWorld;
//   row_major float4x4 gWorldToLocal;
//   row_major float4x4 gWorldToProjection;
//
//
// Registers:
//
//   Name               Reg   Size
//   ------------------ ----- ----
//   gLocalToWorld      c192     4
//   gWorldToLocal      c200     3
//   gWorldToProjection c204     4
//   gCameraPos         c208     1
//   gFogStart          c209     1
//   gFogEnd            c210     1
//   gFogDensity        c211     1
//   gFogType           c223     1
//

    vs_3_0
   def c230, 0, 1, 0.0625, 0.5
dcl_2d s3
    def c0, -1, -2, -3, 0
    def c1, 1, 0, 1.44269502, 0
    dcl_position v0
    dcl_color v1
    dcl_normal v2
    dcl_texcoord v3
    dcl_texcoord1 v4
    dcl_texcoord2 v5
    dcl_texcoord3 v6
    dcl_tangent v7
    dcl_binormal v8
    dcl_position o0
    dcl_texcoord7 o1
    dcl_color1 o2
    dcl_fog o3.x
    dcl_texcoord o4
    dcl_texcoord1 o5
    dcl_texcoord2 o6
    dcl_texcoord3 o7
    dcl_texcoord4 o8
    dcl_texcoord5 o9
    dcl_texcoord6 o10
texldl r22, c230.z, s3
    mov r0.x, c210.x
    add r0.x, r0.x, -c209.x
    rcp r0.x, r0.x
    mov r1.x, c223.x
    add r0.yzw, r1.x, c0.xxyz
    sge r0.yzw, -r0_abs, r0_abs
    abs r1.x, c223.x
    sge r1.x, -r1.x, r1.x
    mad r2, v0.xyzx, c1.xxxy, c1.yyyx
    dp4 r3.x, c192, r2
    dp4 r3.y, c193, r2
    dp4 r3.z, c194, r2
    dp4 r3.w, c195, r2

    add r1.yzw, -r3.xxyz, c208.xxyz
    dp3 r2.x, r1.yzww, r1.yzww
    rsq r2.x, r2.x
    rcp r2.x, r2.x
    mul r2.y, r2.x, c211.x
    add r2.x, -r2.x, c210.x
    mul r2.z, r2.y, c1.z
    mul r2.y, r2.y, r2.y
    exp r2.z, r2.z
    rcp r2.z, r2.z
    mad r0.y, r2.z, r0.y, r1.x
    mul r1.x, r2.y, c1.z
    exp r1.x, r1.x
    rcp r1.x, r1.x
    mad r0.y, r1.x, r0.z, r0.y
    mul r0.z, r0.x, r2.x
    mad r0.y, r0.z, r0.w, r0.y
    mad_sat o3.x, c209.x, r0.x, r0.y
    dp4 r0.x, c204, r3
    dp4 r0.y, c205, r3
    dp4 r0.z, c206, r3
    dp4 r0.w, c207, r3
    mov o6, r3
    mov o0, r0
    
    add r22.w, r0.w, -r22.y
    mad r0.x, r22.x, r22.w, r0.x
    mov o1, r0
    mov o2, v1
    mov o4.xy, v3
    mov o4.zw, v4.xyxy
    mov o5.xy, v5
    mov o5.zw, v6.xyxy
    mov o7.w, c1.y
mul r21.x, r22.y, c204.x
mul r21.y, r22.y, c204.y
mul r21.z, r22.y, c204.z
mov r21.w, c0.w
mul r20.x, c204.x, c204.x
mad r20.x, c204.y, c204.y, r20.x
mad r20.x, c204.z, c204.z, r20.x
rcp r20.x, r20.x
mul r21, r21, r20.x
mad r1.y, r22.x, r21.x, r1.y
mad r1.z, r22.x, r21.y, r1.z
mad r1.w, r22.x, r21.z, r1.w
    mov o7.xyz, r1.yzww
    mul r0.xyz, c201, v7.y
    mad r0.xyz, c200, v7.x, r0
    mad r0.xyz, c202, v7.z, r0
    mov o8.x, r0.x
    mul r2.xyz, c201, -v8.y
    mad r2.xyz, c200, -v8.x, r2
    mad r2.xyz, c202, -v8.z, r2
    mov o8.y, r2.x
    mul r3.xyz, c201, v2.y
    mad r3.xyz, c200, v2.x, r3
    mad r3.xyz, c202, v2.z, r3
    mov o8.z, r3.x
    dp3 r0.x, c201, r1.yzww
    mul r4.xyz, r0.x, -v8
    dp3 r0.x, c200, r1.yzww
    dp3 r0.w, c202, r1.yzww
    mad r1.xyz, v7, r0.x, r4
    mad r1.xyz, v2, r0.w, r1
    mov o8.w, r1.x
    mov o9.x, r0.y
    mov o10.x, r0.z
    mov o9.y, r2.y
    mov o10.y, r2.z
    mov o9.z, r3.y
    mov o10.z, r3.z
    mov o9.w, r1.y
    mov o10.w, r1.z

// approximately 72 instruction slots used
