vf_bumpreflect
{
  material=metal
  vertex_shader
  {
    file=dyn_standard_bump_reflect_v.cg
  }
  fragment_shader
  {
    file=dyn_standard_bump_reflect_f.cg
  }
  fresnel
  {
    bias=0.02
    scale=0.98
    power=5.0
  }
}
vf_bump
{
  material=metal
  vertex_shader
  {
    file=dyn_standard_bump_v.cg
  }
  fragment_shader
  {
    file=dyn_standard_bump_f.cg
  }
}
vf_glass
{
  material=metal
  vertex_shader
  {
    ;file=dyn_standard_bump_reflect_v.cg
    file=dyn_standard_reflect_window_v.cg
  }
  fragment_shader
  {
    ;file=dyn_standard_bump_reflect_f.cg
    file=cg\dyn_standard_reflect_window2_f.cg
  }
  fresnel
  {
    bias=0.05
    scale=0.95
    power=5.0
  }
}
vf_reflect
{
  material=metal
  vertex_shader
  {
    file=dyn_standard_reflect_v.cg
  }
  fragment_shader
  {
    file=dyn_standard_reflect_f.cg
  }
  fresnel
  {
    bias=0.02
    scale=0.98
    power=5.0
  }
}
vf_dir_reflect~vf_reflect
{
  vertex_shader
  {
    file=cg\stereo_directional_reflect_v.cg
  }
  fragment_shader
  {
    file=cg\stereo_directional_reflect_f.cg
  }
}
vf_standard
{
  material=metal
  vertex_shader
  {
    file=dyn_standard_v.cg
  }
  fragment_shader
  {
    file=standard_f.cg
  }
}


shader_body_gloss~vf_bumpreflect
{
  cast_shadow=1
  compression=0
  reflect=.9 ;
  specular=.13 .13 .13
  shininess=12 ; 6
  tangents=1
  layer0
  {
    map=textures\body_pearlwhite.tga
  }
  layer1
  {
    map=textures\body_normal.tga
    mode=linear
  }
  layer2
  {
    map=$trackenvmap
  }
}

; basically the front air dam.  Uses mipmap_bias'd reflection.
shader_body_matte~vf_reflect
{
  reflect=0.3
  cast_shadow=1
  specular=.25 .25 .25
  shininess=60
  mipmap_bias=7
  
  layer0
  {
    map=textures\body_pearlwhite.tga
  }
  layer1
  {
    map=$trackenvmap
  }
}

; ceiling, floor, doors, center console - all views
shader_interior00~vf_reflect
{
  cast_shadow=1
  reflect=0.1
  mipmap_bias=7
  specular=0 0 0
  layer0
  {
    map=textures\interior00.tga
  }
  layer1
  {
    map=$trackenvmap
  }
  fresnel
  {
    bias=0.4
    scale=0.6
    power=1.5
  }
}

; dashboard, low-res exterior model
shader_interior01~vf_reflect
{
  cast_shadow=1
  reflect=0.03
  mipmap_bias=6.6
  specular=0 0 0
  layer0
  {
    map=textures\interior01.tga
  }
  layer1
  {
    map=$trackenvmap
  }
  fresnel
  {
    bias=0.4
    scale=0.6
    power=1.5
  }
}

; higher resolution dash texture, interior model
shader_interior02~vf_reflect
{
  reflect=0.06
  mipmap_bias=6.6
  specular=0 0 0
  layer0
  {
    map=textures\interior02.tga
  }
  layer1
  {
    map=$trackenvmap
  }
  fresnel
  {
    bias=0.4
    scale=0.6
    power=1.5
  }
}

; driver, visible exterior only
shader_driver00~vf_standard
{
  cast_shadow=1
  layer0
  {
    map=textures\driver.tga
  }
}

; steering wheel, both interior and exterior
shader_strwheel~vf_standard
{
  cast_shadow=1
  layer0
  {
    map=textures\strwheel_noalpha.tga
  }
}

; underside, plus inserts of front openings and vent across bottom of windshield
shader_grey00~vf_standard
{
  cast_shadow=1 ; mostly for the top of the hood
  layer0
  {
    map=textures\black.tga
  }
}

; reflective mirrors, interior model only - uv mapping's broken on the exterior or something
shader_mirror
{
  diffuse=0 0 0
  ambient=0.01 0.01 0.01
  layer0 
  {
    map=$mirror
    texscale_s=1
    texscale_r=1
    texscale_t=1
    emission=.3 .3 .3 1
  }
}

; window glass, and the frames surrounding it
shader_transparent_glass~vf_glass
{
  sort_offset=2
  reflect=1
      shininess=40
      specular=0 0 0 1
  layer0
  {
    map=textures\transp3.tga
  }
  layer1
  {
    map=$trackenvmap
    blendfunc=blend
  }
}

; badges. could use a bump mapping.
shader_transparent_decal~vf_reflect
{
  compression=0
  depthwrite=0
  reflect=0.5
  specular=.1 .1 .1
  shininess=50
  tangents=1
  sort_offset=2
  layer0
  {
    map=textures\transp3.tga
  }
  layer1
  {
    map=$trackenvmap
    blendfunc=src_alpha one_minus_src_alpha
  }
}

; glass seen from the inside, doesn't reflect so as not to annoy.
shader_transparent_interior~vf_standard
{
  sort_offset=1
  layer0
  {
    alphafunc=gequal 150
    map=textures\transp2.tga
    blendfunc = one one_minus_src_alpha
  }
}

; pop-up headlights emissive material
shader_glow_lights~vf_standard
{
  ambient=0 0 0
  diffuse=0 0 0
  emission=30 30 30
  sort_offset=1
  depthwrite=1
  layer0
  {
    map=textures\glow_lights.tga
    blendfunc=add
  }
}
; some of it seems to need a separate sort offset to render ok
shader_glow_lights_postpone~shader_glow_lights
{
  sort_offset=3
}


; The outer surface of highest LOD wheel.
shader_wheel~vf_dir_reflect
{
  cast_shadow=1
  ; emission is 3 vector for direction to accept refl.
  emission=0.0 0.0 0.0
  compression=0
  reflect=1.0
  specular=.6 .6 .6 1 ; .15
  shininess=16
  mipmap_bias=7
  ;tangents=1
  layer0
  {
    map=textures\wheel.tga
    ;blendfunc=blend 
  }
  layer1
  {
    map=$trackenvmap
  }
  fresnel
  {
    bias=0.1
    scale=0.9
    power=5
  }
}
shader_wheel_l~shader_wheel
{
  emission=1.0 0.0 0.0
}
shader_wheel_r~shader_wheel
{
  emission=-1.0 0.0 0.0
}

; all the tire, back/side/front
shader_tire~vf_bump
{
  cast_shadow=1
  motion_blur=0
      emission=0 0 0 1
      shininess=10
      specular=.2 .2 .2 1
  tangents=1
  mipmap_bias=7
  reflect=0.0
  layer0
  {
    map=textures\tire_foxo.tga
  }
  layer1
  {
    map=textures\tire_foxo_bump.tga
    mode=linear
  }
}

; brake discs as well as calipers
shader_rotor
{
  motion_blur=0
  ; Brake disc
  layer0
  {
    map=textures\brake.tga
    emission=0 0 0 1
    shininess=32
    specular=.3 .3 .3 1
  }
  ; Brakedisc heat shader
  vertex_shader
  {
    file=dyn_standard_v.cg
  }
  fragment_shader
  {
    ; Use disc heat global shader
    file=standard_heat_f.cg
  }
}

; interior model rpm/kph dials
shader_rpm~vf_standard
{
  layer0
  {
    map=textures\rpm.tga
  }
  fragment_shader
  {
    file=standard_f.cg
  }
}

shader_kph~vf_standard
{
  layer0
  {
    map=textures\kmh.tga
  }
  fragment_shader
  {
    file=standard_f.cg
  }
}

; the collision object has a shader for some reason
shader_default_material~vf_standard
{
  material=metal
  layer0
  {
    map=textures\neontest.tga
  }
}