diff --git a/modules/juce_opengl/opengl/juce_OpenGLFrameBuffer.cpp b/modules/juce_opengl/opengl/juce_OpenGLFrameBuffer.cpp index 688b000bd8..30e9cc318d 100644 --- a/modules/juce_opengl/opengl/juce_OpenGLFrameBuffer.cpp +++ b/modules/juce_opengl/opengl/juce_OpenGLFrameBuffer.cpp @@ -59,8 +59,7 @@ public: Pimpl (OpenGLContext& c, const int w, const int h, const bool wantsDepthBuffer, const bool wantsStencilBuffer) : context (c), width (w), height (h), - textureID (0), frameBufferID (0), depthOrStencilBuffer (0), - hasDepthBuffer (false), hasStencilBuffer (false) + textureID (0), frameBufferID (0), depthOrStencilBuffer (0) { // Framebuffer objects can only be created when the current thread has an active OpenGL // context. You'll need to create this object in one of the OpenGLContext's callbacks. @@ -114,9 +113,6 @@ public: if (wantsStencilBuffer) context.extensions.glFramebufferRenderbuffer (GL_FRAMEBUFFER, GL_STENCIL_ATTACHMENT, GL_RENDERBUFFER, depthOrStencilBuffer); - - hasDepthBuffer = wantsDepthBuffer; - hasStencilBuffer = wantsStencilBuffer; } unbind(); @@ -160,19 +156,10 @@ public: OpenGLContext& context; const int width, height; GLuint textureID, frameBufferID, depthOrStencilBuffer; - bool hasDepthBuffer, hasStencilBuffer; private: GLint prevFramebuffer{}; - bool checkStatus() noexcept - { - const GLenum status = context.extensions.glCheckFramebufferStatus (GL_FRAMEBUFFER); - - return status == GL_NO_ERROR - || status == GL_FRAMEBUFFER_COMPLETE; - } - JUCE_DECLARE_NON_COPYABLE (Pimpl) };