/*******************************************************************/
/*                                                                 */
/* Module: flora_ps.cg                                             */
/*                                                                 */
/* Author: John Buckley                                            */
/*                                                                 */
/* Description:                                                    */
/*                                                                 */
/*   Flora Material Class                                          */
/*                                                                 */
/* Copyright 2005 Sony Online Entertainment.  All rights reserved. */
/*                                                                 */
/*******************************************************************/

#include"flora_common.cg"

/**********************************/
/* Pixel Shader                   */
/**********************************/

float4 main( Fragment_Flora In,
             uniform sampler2D     ColorTex : TEXUNIT0,
             uniform float3        FogColor,
             uniform float         FogOn ) : COLOR
 {
  float4 Out;

  float4 ColorTexColor = tex2D( ColorTex, In.ColorUV );

  Out.rgb = lerp((float3)(ColorTexColor * In.Diff), (float3)FogColor, In.FogDepth*FogOn);
  Out.a   = ColorTexColor.a * In.Diff.a;

  return Out;
 }

/* End of File */
