This commit is contained in:
Vasily Petrov 2026-06-18 01:18:29 +03:00
commit 2fe6ca2f65
1473 changed files with 251771 additions and 0 deletions

View file

@ -0,0 +1,37 @@
#include "common.hlsli"
struct vv
{
float4 P : POSITION;
float2 tc : TEXCOORD0;
float4 c : COLOR0;
};
struct v2p_particle
{
float4 color : COLOR0;
p_flat base;
};
v2p_particle main(vv I)
{
float4 w_pos = I.P;
// Eye-space pos/normal
p_flat O;
O.hpos = mul(m_WVP, w_pos);
O.N = normalize(eye_position - w_pos);
float3 Pe = mul(m_WV, I.P);
O.tcdh = float4(I.tc.xyyy);
O.position = float4(Pe, .2h);
#ifdef USE_TDETAIL
O.tcdbump = O.tcdh * dt_params; // dt tc
#endif
v2p_particle pp;
pp.color = I.c;
pp.base = O;
return pp;
}