[Piglit] [PATCH 13/15] arb_direct_state_access: Testing NamedFramebufferReadBuffer.

Laura Ekstrand laura at jlekstrand.net
Thu Mar 5 18:01:23 PST 2015


---
 tests/spec/arb_direct_state_access/drawbuffers.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/tests/spec/arb_direct_state_access/drawbuffers.c b/tests/spec/arb_direct_state_access/drawbuffers.c
index 99ebf06..840a39f 100644
--- a/tests/spec/arb_direct_state_access/drawbuffers.c
+++ b/tests/spec/arb_direct_state_access/drawbuffers.c
@@ -65,7 +65,10 @@ clear_to_color(float color[4], int att)
 static void
 clear_subtest(float color[4], int att, const char *test_name)
 {
-	glReadBuffer(GL_COLOR_ATTACHMENT0 + att);
+	glBindFramebuffer(GL_READ_FRAMEBUFFER, 0);
+	glNamedFramebufferReadBuffer(fbo, GL_COLOR_ATTACHMENT0 + att);
+	glBindFramebuffer(GL_READ_FRAMEBUFFER, fbo);
+
 	piglit_check_gl_error(GL_NO_ERROR);
 	SUBTESTCONDITION(piglit_probe_rect_rgb(0, 0, piglit_width,
 			 piglit_height, color), pass, test_name);
-- 
2.1.0



More information about the Piglit mailing list