//
//morphlet_Fist
//

#define X ps_in.tex0.x
#define Y ps_in.tex0.y

float4x4 scale_matrix;

struct VS_INPUT
{
    float3 pos : POSITION;
    float2 tex0 : TEXCOORD0;
};

struct VS_OUTPUT
{
    float4 pos   : POSITION;
    float2 tex0  : TEXCOORD0;
};

VS_OUTPUT VS(VS_INPUT vertex_in)
{
    float4 u;
    VS_OUTPUT vertex_out = (VS_OUTPUT)0;

    vertex_out.pos = mul(float4(vertex_in.pos,1),scale_matrix);
   // vertex_out.pos = float4(vertex_in.pos,1);
    vertex_out.tex0 = vertex_in.tex0;

    return vertex_out;
}


struct PS_INPUT
{
  float2 tex0 : TEXCOORD0;
};

struct PS_OUTPUT
{
  float4 color : COLOR;
};


PS_OUTPUT PS(PS_INPUT ps_in)
{
   PS_OUTPUT ps_out = (PS_OUTPUT)0;
   
   float x2y2=X*X+Y*Y;
   ps_out.color =(x2y2<=1.0f)? exp(-22.2f*pow(sqrt(x2y2)-0.5f,2)) : 0.0f;
   


   return ps_out;
}




technique T0
{

    pass P0
    {

    }
}


