1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-02-06 10:45:33 +00:00

Merge branch 'normalizedsun' into 'master'

Actually normalize the sun position exposed to post-processing

See merge request OpenMW/openmw!3820
This commit is contained in:
psi29a 2024-01-31 10:50:31 +00:00
commit 5ca8f7a00e

View file

@ -43,6 +43,7 @@ namespace fx
void setSunPos(const osg::Vec4f& pos, bool night)
{
mData.get<SunPos>() = pos;
mData.get<SunPos>().normalize();
if (night)
mData.get<SunPos>().z() *= -1.f;