e4s-sdk/gamedata/shaders/d3d11/stub_screen_space.vs.hlsl
2026-06-17 23:06:51 +03:00

17 lines
360 B
HLSL

#include "common.hlsli"
// Vertex
uniform float4 screen_res;
p_shadow main(v2p_screen I)
{
p_shadow O;
// Transform to screen space (in d3d9 it was done automatically)
O.hpos.x = (I.HPos.x * screen_res.z * 2 - 1);
O.hpos.y = -(I.HPos.y * screen_res.w * 2 - 1);
O.hpos.zw = I.HPos.zw;
O.tc0 = I.tc0;
return O;
}