<html>
<head>
<base href="https://bugs.freedesktop.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Reading back an EGL Pbuffer using the OpenGL API returns garbled output"
href="https://bugs.freedesktop.org/show_bug.cgi?id=108977">108977</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Reading back an EGL Pbuffer using the OpenGL API returns garbled output
</td>
</tr>
<tr>
<th>Product</th>
<td>Mesa
</td>
</tr>
<tr>
<th>Version</th>
<td>18.2
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Other
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Component</th>
<td>EGL
</td>
</tr>
<tr>
<th>Assignee</th>
<td>mesa-dev@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>matthieu.bouron@gmail.com
</td>
</tr>
<tr>
<th>QA Contact</th>
<td>mesa-dev@lists.freedesktop.org
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=142750" name="attach_142750" title="EGL pbuffer test">attachment 142750</a> <a href="attachment.cgi?id=142750&action=edit" title="EGL pbuffer test">[details]</a></span>
EGL pbuffer test
Hello,
I am currently facing an issue while reading back EGL Pbuffers using
glReadPixels() with the OpenGL API as the output is garbled. It properly works
with the OpenGL ES API though.
I can reproduce the issue on different machines running Arch Linux with mesa
18.2.5 on X using the following GPU: Intel HD 5500, Intel Iris 580 Pro, AMD RX
580.
I am not able to reproduce the issue on an NVDIA GTX 1070 running the
proprietary driver.
I have attached a sample code that reproduces the issue:
On OpenGL:
gcc `pkg-config --libs egl gl` -Wall egl-pbuffer.c -o egl-pbuffer
&&./egl-pbuffer
0xff69fc07 0xff69fc07 0xff69fc07 0xff69fc07
0xff69fc07 0xff11a1e4 0xff000000 0xff000000
0xff69fc07 0xff000000 0xff7fc700 0xff000000
0xff69fc07 0xff000000 0xff000000 0xff3a4e3b
On OpenGLES (adding the -es parameter to ./egl-pbuffer):
gcc `pkg-config --libs egl gl` -Wall egl-pbuffer.c -o egl-pbuffer
&&./egl-pbuffer -es
0xff0000ff 0xff0000ff 0xff0000ff 0xff0000ff
0xff0000ff 0xff0000ff 0xff0000ff 0xff0000ff
0xff0000ff 0xff0000ff 0xff0000ff 0xff0000ff
0xff0000ff 0xff0000ff 0xff0000ff 0xff0000ff</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
<li>You are the QA Contact for the bug.</li>
</ul>
</body>
</html>