- fixed rendering of environment map on mirrors

With temporarily mapped buffer this feature seems to never work correctly
With persistently mapped buffer it was broken in 9a1603b246
This commit is contained in:
alexey.lysiuk 2018-05-30 15:46:53 +03:00
parent 4e6226fc2d
commit 4f5911da21

View file

@ -351,6 +351,9 @@ void FDrawInfo::AddMirrorSurface(GLWall *w)
auto newwall = drawlists[GLDL_TRANSLUCENTBORDER].NewWall();
*newwall = *w;
// Invalidate vertices to allow setting of texture coordinates
newwall->vertcount = 0;
FVector3 v = newwall->glseg.Normal();
auto tcs = newwall->tcs;
tcs[GLWall::LOLFT].u = tcs[GLWall::LORGT].u = tcs[GLWall::UPLFT].u = tcs[GLWall::UPRGT].u = v.X;