home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
GameStar 2006 April
/
Gamestar_83_2006-04_dvd.iso
/
Dema
/
demowot_english.exe
/
InfDX
/
Shaders
/
aoc-vertex.hlsl
< prev
next >
Wrap
Text File
|
2005-07-12
|
433b
|
26 lines
#include "generic-include.hlsl"
struct VSOutput
{
float4 Position : POSITION0;
float Distance : TEXCOORD0;
};
VSOutput main(StdVSInput In)
{
VSOutput Out;
float4 LocalPosition=StdVSLocalPosition(In);
Out.Position=StdVSLocalToProjection(LocalPosition, In);
Out.Distance=length(mul(LocalPosition, TDX_CONST_WORLDVIEW).xyz)*TDX_CONST_FOGPLANES.w;
// Out.Distance*=Out.Distance;
return Out;
}