Commit 6830eb60 by Mohan Maiya Committed by Commit Bot

EGL: Fix a bug in ImageTest

During cleanup, we were incorrectly calling glDeleteRenderbuffers on a texture object. Also update comments to correctly reflect intent. Bug: angleproject:5018 Change-Id: I28eaf6a23056f3b09eebb7331620e6a27cb14302 Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2406614Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org> Commit-Queue: Mohan Maiya <m.maiya@samsung.com>
parent 68af795d
...@@ -1757,13 +1757,13 @@ void ImageTest::Source2DTargetExternal_helper(const EGLint *attribs) ...@@ -1757,13 +1757,13 @@ void ImageTest::Source2DTargetExternal_helper(const EGLint *attribs)
GLuint target; GLuint target;
createEGLImageTargetTextureExternal(image, &target); createEGLImageTargetTextureExternal(image, &target);
// Expect that the target renderbuffer has the same color as the source texture // Expect that the target texture when sampled has the same color as the source image
verifyResultsExternal(target, data); verifyResultsExternal(target, data);
// Clean up // Clean up
glDeleteTextures(1, &source); glDeleteTextures(1, &source);
eglDestroyImageKHR(window->getDisplay(), image); eglDestroyImageKHR(window->getDisplay(), image);
glDeleteRenderbuffers(1, &target); glDeleteTextures(1, &target);
} }
TEST_P(ImageTestES3, Source2DTargetExternalESSL3) TEST_P(ImageTestES3, Source2DTargetExternalESSL3)
...@@ -1795,13 +1795,13 @@ void ImageTest::Source2DTargetExternalESSL3_helper(const EGLint *attribs) ...@@ -1795,13 +1795,13 @@ void ImageTest::Source2DTargetExternalESSL3_helper(const EGLint *attribs)
GLuint target; GLuint target;
createEGLImageTargetTextureExternal(image, &target); createEGLImageTargetTextureExternal(image, &target);
// Expect that the target renderbuffer has the same color as the source texture // Expect that the target texture when sampled has the same color as the source image
verifyResultsExternalESSL3(target, data); verifyResultsExternalESSL3(target, data);
// Clean up // Clean up
glDeleteTextures(1, &source); glDeleteTextures(1, &source);
eglDestroyImageKHR(window->getDisplay(), image); eglDestroyImageKHR(window->getDisplay(), image);
glDeleteRenderbuffers(1, &target); glDeleteTextures(1, &target);
} }
TEST_P(ImageTest, SourceCubeTarget2D) TEST_P(ImageTest, SourceCubeTarget2D)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment