From b24fa749362f7ba8fa93e50bb64521d969a26b55 Mon Sep 17 00:00:00 2001 From: kaetemi Date: Mon, 4 Aug 2014 07:38:40 +0200 Subject: [PATCH] 3D: Fix texture coords for FXAA on D3D --- code/nel/src/3d/fxaa.cpp | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/code/nel/src/3d/fxaa.cpp b/code/nel/src/3d/fxaa.cpp index a0fe90ecc..238303001 100644 --- a/code/nel/src/3d/fxaa.cpp +++ b/code/nel/src/3d/fxaa.cpp @@ -148,10 +148,20 @@ CFXAA::CFXAA(NL3D::UDriver *driver) : m_Driver(driver), m_PP(NULL), m_VP(NULL), m_QuadUV.V2 = CVector(1.f, 1.f, 0.5f); m_QuadUV.V3 = CVector(0.f, 1.f, 0.5f); - m_QuadUV.Uv0 = CUV(0.f, 0.f); - m_QuadUV.Uv1 = CUV(1.f, 0.f); - m_QuadUV.Uv2 = CUV(1.f, 1.f); - m_QuadUV.Uv3 = CUV(0.f, 1.f); + if (drv->textureCoordinateAlternativeMode()) + { + m_QuadUV.Uv0 = CUV(0.f, 1.f); + m_QuadUV.Uv1 = CUV(1.f, 1.f); + m_QuadUV.Uv2 = CUV(1.f, 0.f); + m_QuadUV.Uv3 = CUV(0.f, 0.f); + } + else + { + m_QuadUV.Uv0 = CUV(0.f, 0.f); + m_QuadUV.Uv1 = CUV(1.f, 0.f); + m_QuadUV.Uv2 = CUV(1.f, 1.f); + m_QuadUV.Uv3 = CUV(0.f, 1.f); + } /*CVertexBuffer &vb = m_VB; vb.clearValueEx();