blob: b1a29833d77fcdcf64ee87aecf99fb08f68311d8 (
plain)
1
2
3
4
5
6
7
8
|
void camera(out vec3 outview, out float outdepth, out float outdist)
{
vec3 vP = transform_point(ViewMatrix, g_data.P);
vP.z = -vP.z;
outdepth = abs(vP.z);
outdist = length(vP);
outview = normalize(vP);
}
|