Revert "Remove non-const FBO attachment queries."
Compile errors on Mac:
In file included from ../../third_party/angle/src/libANGLE/Framebuffer.cpp:10:
In file included from ../../third_party/angle/src/libANGLE/Framebuffer.h:13:
In file included from /Applications/Xcode5.1.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.6.sdk/usr/include/c++/4.2.1/vector:68:
/Applications/Xcode5.1.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.6.sdk/usr/include/c++/4.2.1/bits/stl_construct.h:81:38: error: call to implicitly-deleted copy constructor of 'gl::FramebufferAttachment'
::new(static_cast<void*>(__p)) _T1(__value);
^ ~~~~~~~
This reverts commit ed61a5f673cefe1fac580e96adaa3da698d448e3.
Change-Id: I602bffc96f77cffa217cb63a5cc3caf334fd9879
Reviewed-on: https://chromium-review.googlesource.com/266652
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Tested-by: Jamie Madill <jmadill@chromium.org>
diff --git a/src/libANGLE/validationES.cpp b/src/libANGLE/validationES.cpp
index 688202e..350f6f6 100644
--- a/src/libANGLE/validationES.cpp
+++ b/src/libANGLE/validationES.cpp
@@ -498,8 +498,8 @@
return false;
}
- const gl::Framebuffer *readFramebuffer = context->getState().getReadFramebuffer();
- const gl::Framebuffer *drawFramebuffer = context->getState().getDrawFramebuffer();
+ gl::Framebuffer *readFramebuffer = context->getState().getReadFramebuffer();
+ gl::Framebuffer *drawFramebuffer = context->getState().getDrawFramebuffer();
if (!readFramebuffer || !drawFramebuffer)
{
@@ -597,7 +597,7 @@
{
if (drawFramebuffer->isEnabledColorAttachment(colorAttachment))
{
- const FramebufferAttachment *attachment = drawFramebuffer->getColorbuffer(colorAttachment);
+ FramebufferAttachment *attachment = drawFramebuffer->getColorbuffer(colorAttachment);
ASSERT(attachment);
if (!(attachment->type() == GL_TEXTURE && attachment->getTextureImageIndex().type == GL_TEXTURE_2D) &&