<div dir="ltr">Hi,<div>is this patch alright? I'm asking because nobody commented this yet and I don't see the patch pushed to Piglit.</div><div><br></div><div>Thanks,</div><div>Sandra</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, May 5, 2017 at 1:45 PM, Sandra Koroniewska <span dir="ltr"><<a href="mailto:sandra.koroniewska@gmail.com" target="_blank">sandra.koroniewska@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">This fixes tests/spec/gl-2.1/pbo on Windows Intel driver. According to OpenGL 2.1 spec, page 38 "Unmapping a mapped buffer<br>
object invalidates the pointers to its data store and sets the object’s<br>
BUFFER MAPPED state to FALSE and its BUFFER MAP POINTER state to NULL." and to page 251 about GetPixelMap "If a pixel pack buffer is bound (as indicated by a non-zero value of<br>
PIXEL PACK BUFFER BINDING), data is an offset into the pixel pack buffer; otherwise,<br>
data is a pointer to client memory".<br>
---<br>
tests/spec/gl-2.1/pbo.c | 3 +--<br>
1 file changed, 1 insertion(+), 2 deletions(-)<br>
<br>
diff --git a/tests/spec/gl-2.1/pbo.c b/tests/spec/gl-2.1/pbo.c<br>
index bb4c0352c..1b561f7cb 100644<br>
--- a/tests/spec/gl-2.1/pbo.c<br>
+++ b/tests/spec/gl-2.1/pbo.c<br>
@@ -305,7 +305,6 @@ test_pixel_map(void)<br>
pbo_mem[i] = max - i - 1;<br>
<br>
if (use_unpack) {<br>
- glUnmapBufferARB(GL_PIXEL_<wbr>UNPACK_BUFFER_ARB);<br>
glPixelMapusv(GL_PIXEL_MAP_R_<wbr>TO_R, max, NULL);<br>
glPixelMapusv(GL_PIXEL_MAP_G_<wbr>TO_G, max, NULL);<br>
glPixelMapusv(GL_PIXEL_MAP_B_<wbr>TO_B, max, NULL);<br>
@@ -353,7 +352,7 @@ test_pixel_map(void)<br>
}<br>
<br>
for (i = 0; i < max; i++) {<br>
- if (pbo_mem[i] != (255 - i)) {<br>
+ if (pbo_mem[i] != (max - i - 1)) {<br>
REPORT_FAILURE("get PixelMap failed");<br>
return PIGLIT_FAIL;<br>
}<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.11.0.windows.1<br>
<br>
</font></span></blockquote></div><br></div>