From ce7357ffa4e9be916795716a16341f63aca2dcbc Mon Sep 17 00:00:00 2001 From: kaetemi Date: Fri, 13 Sep 2013 17:17:11 +0200 Subject: [PATCH] Do not use old interface here --- code/nel/src/3d/driver/opengl/driver_opengl.cpp | 6 ++++-- code/nel/src/3d/vegetable_manager.cpp | 2 +- code/ryzom/client/src/decal.cpp | 2 +- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/code/nel/src/3d/driver/opengl/driver_opengl.cpp b/code/nel/src/3d/driver/opengl/driver_opengl.cpp index 3eff7eebf..946e69ee0 100644 --- a/code/nel/src/3d/driver/opengl/driver_opengl.cpp +++ b/code/nel/src/3d/driver/opengl/driver_opengl.cpp @@ -1415,11 +1415,13 @@ void CDriverGL::setupFog(float start, float end, CRGBA color) // last constant is used to store fog information (fog must be rescaled to [0, 1], because of a driver bug) if (start != end) { - setConstant(_EVSNumConstant, 1.f / (start - end), - end / (start - end), 0, 0); + float datas[] = { 1.f / (start - end), - end / (start - end), 0, 0 }; + nglSetInvariantEXT(_EVSConstantHandle + _EVSNumConstant, GL_FLOAT, datas); } else { - setConstant(_EVSNumConstant, 0.f, 0, 0, 0); + float datas[] = { 0.f, 0, 0, 0 }; + nglSetInvariantEXT(_EVSConstantHandle + _EVSNumConstant, GL_FLOAT, datas); } } } diff --git a/code/nel/src/3d/vegetable_manager.cpp b/code/nel/src/3d/vegetable_manager.cpp index f2c8457f8..ba5f721bb 100644 --- a/code/nel/src/3d/vegetable_manager.cpp +++ b/code/nel/src/3d/vegetable_manager.cpp @@ -2400,7 +2400,7 @@ void CVegetableManager::setupRenderStateForBlendLayerModel(IDriver *driver) /*if (fogged) // duplicate { - driver->setConstantFog(6); + driver->setCon/stantFog(6); }*/ // Activate the unique material (correclty setuped for AlphaBlend in render()). diff --git a/code/ryzom/client/src/decal.cpp b/code/ryzom/client/src/decal.cpp index 5649b9b57..a1cca247d 100644 --- a/code/ryzom/client/src/decal.cpp +++ b/code/ryzom/client/src/decal.cpp @@ -621,7 +621,7 @@ void CDecalRenderList::renderAllDecals() if (!forceNoVertexProgram && drvInternal->compileVertexProgram(&DecalAttenuationVertexProgram)) { drvInternal->activeVertexProgram(&DecalAttenuationVertexProgram); - //drvInternal->setConstantMatrix(0, NL3D::IDriver::ModelViewProjection, NL3D::IDriver::Identity); + //drvInternal->setCons/tantMatrix(0, NL3D::IDriver::ModelViewProjection, NL3D::IDriver::Identity); drvInternal->setUniform4f(IDriver::VertexProgram, DecalAttenuationVertexProgram.idx().DistScaleBias, _DistScale, _DistBias, 0.f, 1.f); useVertexProgram = true; }