Changeset View
Changeset View
Standalone View
Standalone View
source/renderer/Renderer.cpp
Show First 20 Lines • Show All 1,418 Lines • ▼ Show 20 Lines | |||||
#if !CONFIG2_GLES | #if !CONFIG2_GLES | ||||
// Clean up texture blend mode so particles and other things render OK | // Clean up texture blend mode so particles and other things render OK | ||||
// (really this should be cleaned up by whoever set it) | // (really this should be cleaned up by whoever set it) | ||||
glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); | glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); | ||||
#endif | #endif | ||||
// render debug lines | // render debug lines | ||||
if (g_RenderingOptions.GetDisplayFrustum()) | if (g_RenderingOptions.GetDisplayFrustum()) | ||||
{ | |||||
DisplayFrustum(); | DisplayFrustum(); | ||||
if (g_RenderingOptions.GetDisplayShadowsFrustum()) | |||||
{ | |||||
m->shadow.RenderDebugBounds(); | m->shadow.RenderDebugBounds(); | ||||
m->shadow.RenderDebugTexture(); | m->shadow.RenderDebugTexture(); | ||||
ogl_WarnIfError(); | |||||
} | } | ||||
m->silhouetteRenderer.RenderDebugOverlays(m_ViewCamera); | m->silhouetteRenderer.RenderDebugOverlays(m_ViewCamera); | ||||
// render overlays that should appear on top of all other objects | // render overlays that should appear on top of all other objects | ||||
m->overlayRenderer.RenderForegroundOverlays(m_ViewCamera); | m->overlayRenderer.RenderForegroundOverlays(m_ViewCamera); | ||||
ogl_WarnIfError(); | ogl_WarnIfError(); | ||||
▲ Show 20 Lines • Show All 54 Lines • ▼ Show 20 Lines | #else | ||||
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); | glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); | ||||
glColor3ub(255,255,255); | glColor3ub(255,255,255); | ||||
m_CullCamera.Render(2); | m_CullCamera.Render(2); | ||||
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); | glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); | ||||
glEnable(GL_CULL_FACE); | glEnable(GL_CULL_FACE); | ||||
glDepthMask(1); | glDepthMask(1); | ||||
#endif | #endif | ||||
ogl_WarnIfError(); | |||||
} | } | ||||
/////////////////////////////////////////////////////////////////////////////////////////////////// | /////////////////////////////////////////////////////////////////////////////////////////////////// | ||||
// Text overlay rendering | // Text overlay rendering | ||||
void CRenderer::RenderTextOverlays() | void CRenderer::RenderTextOverlays() | ||||
{ | { | ||||
PROFILE3_GPU("text overlays"); | PROFILE3_GPU("text overlays"); | ||||
▲ Show 20 Lines • Show All 462 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator