home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
BitJam
/
bitjam1-1.iso
/
interface
/
sign_of_life
/
particle.vs
< prev
next >
Wrap
Text File
|
2007-09-05
|
413b
|
18 lines
float4x4 view_proj_matrix:register(c0);
struct VS_OUTPUT {
float4 Pos: POSITION;
float2 texCoord: TEXCOORD0;
float2 color: TEXCOORD1;
};
VS_OUTPUT main(float3 Pos:POSITION,float2 tx:TEXCOORD0) {
VS_OUTPUT Out;
float4 pos = mul(view_proj_matrix, float4(Pos, 1));
pos.x += tx.x * .2;
pos.y += tx.y * .2;
Out.Pos = pos;
Out.texCoord = tx;
Out.color = clamp(pos.z, 0.5, 1);
return Out;
}