1
0
forked from 0ad/0ad

Removes glColor* calls from scene rendering, colors are set explicitly by uniforms.

This was SVN commit r25330.
This commit is contained in:
Vladislav Belov 2021-04-27 19:35:36 +00:00
parent 5b33d3a76c
commit b74d5bf0d8
3 changed files with 1 additions and 6 deletions

View File

@ -46,7 +46,6 @@ public:
/**
* Render: Renders the camera's frustum in world space.
* The caller should set the color using glColorXy before calling Render.
*
* @param intermediates determines how many intermediate distance planes should
* be hinted at between the near and far planes

View File

@ -604,8 +604,6 @@ void OverlayRenderer::RenderForegroundOverlays(const CCamera& viewCamera)
CVector3D right = -viewCamera.GetOrientation().GetLeft();
CVector3D up = viewCamera.GetOrientation().GetUp();
glColor4f(1.0f, 1.0f, 1.0f, 1.0f);
glEnableClientState(GL_VERTEX_ARRAY);
glEnableClientState(GL_TEXTURE_COORD_ARRAY);

View File

@ -747,7 +747,7 @@ void CRenderer::RenderPatches(const CShaderDefines& context, int cullGroup)
{
// edged faces: need to make a second pass over the data:
// first switch on wireframe
glPolygonMode(GL_FRONT_AND_BACK,GL_LINE);
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
// setup some renderstate ..
pglActiveTextureARB(GL_TEXTURE0);
@ -757,8 +757,6 @@ void CRenderer::RenderPatches(const CShaderDefines& context, int cullGroup)
// render tiles edges
m->terrainRenderer.RenderPatches(cullGroup, CColor(0.5f, 0.5f, 1.0f, 1.0f));
// set color for outline
glColor3f(0, 0, 1);
glLineWidth(4.0f);
// render outline of each patch