From 468b5ffab1a52468473e256e30850a1ad353c5ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Fri, 3 Mar 2023 23:36:00 +0100 Subject: [PATCH] GL: move Renderer *Implementation() definitions next to the public APIs. --- src/Magnum/GL/Renderer.cpp | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/src/Magnum/GL/Renderer.cpp b/src/Magnum/GL/Renderer.cpp index 9aa1ef926..aaf20630c 100644 --- a/src/Magnum/GL/Renderer.cpp +++ b/src/Magnum/GL/Renderer.cpp @@ -100,10 +100,16 @@ void Renderer::setClearDepth(const Double depth) { } #endif -void Renderer::setClearDepth(Float depth) { +void Renderer::setClearDepth(const Float depth) { Context::current().state().renderer.clearDepthfImplementation(depth); } +#ifndef MAGNUM_TARGET_GLES +void Renderer::clearDepthfImplementationDefault(const GLfloat depth) { + glClearDepth(GLdouble(depth)); +} +#endif + void Renderer::setClearStencil(const Int stencil) { glClearStencil(stencil); } @@ -398,6 +404,10 @@ Renderer::ResetNotificationStrategy Renderer::resetNotificationStrategy() { Renderer::GraphicsResetStatus Renderer::graphicsResetStatus() { return Renderer::GraphicsResetStatus(Context::current().state().renderer.graphicsResetStatusImplementation()); } + +GLenum Renderer::graphicsResetStatusImplementationDefault() { + return GL_NO_ERROR; +} #endif void Renderer::initializeContextBasedFunctionality() { @@ -406,18 +416,6 @@ void Renderer::initializeContextBasedFunctionality() { setClearColor(0x1f1f1f_rgbf); } -#ifndef MAGNUM_TARGET_GLES -void Renderer::clearDepthfImplementationDefault(const GLfloat depth) { - glClearDepth(GLdouble(depth)); -} -#endif - -#ifndef MAGNUM_TARGET_WEBGL -GLenum Renderer::graphicsResetStatusImplementationDefault() { - return GL_NO_ERROR; -} -#endif - #ifndef DOXYGEN_GENERATING_OUTPUT Debug& operator<<(Debug& debug, const Renderer::Error value) { debug << "GL::Renderer::Error" << Debug::nospace;