Untitled
By: a guest | Feb 9th, 2010 | Syntax:
C# | Size: 0.71 KB | Hits: 19 | Expires: Never
float4x4 WorldViewProjection : WORLDVIEWPROJECTION;
sampler tex;
struct VertexShaderInput
{
float4 Position : POSITION0;
};
struct VertexShaderOutput
{
float4 Position : POSITION0;
};
VertexShaderOutput VertexShaderFunction(VertexShaderInput input)
{
VertexShaderOutput output;
output.Position = mul(input.Position, WorldViewProjection );
return output;
}
float4 PixelShaderFunction(float2 uv : TEXCOORD0, float4 tint : COLOR0) : COLOR0
{
float4 color = tex2D(tex, uv);
return color * tint;
}
technique Technique1
{
pass Pass1
{
VertexShader = compile vs_1_1 VertexShaderFunction();
PixelShader = compile ps_2_0 PixelShaderFunction();
}
}