<div class="gmail_quote">On Wed, Aug 25, 2010 at 11:44 PM, Brian Paul <span dir="ltr">&lt;<a href="mailto:brianp@vmware.com">brianp@vmware.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

<div><div></div><div class="h5">On 08/25/2010 08:57 AM, Luca Barbieri wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
A new test for ARB_color_buffer_float is attached, which currently has<br>
no tests in either mesa-demos or piglit.<br>
ARB_texture_float is required to test 16-bit and 32-bit floating point<br>
targets, and otherwise only 8-bit fixed-point will tested.<br>
<br>
Mesa does not support this extension, but the proprietary drivers from<br>
both nVidia and ATI advertise it, and have been used to write this<br>
test.<br>
<br>
Note that both nVidia and ATI drivers are nonconformant in serious<br>
ways (and the bugs are all different between them).<br>
<br>
This test detects nVidia and ATI drivers and ignores all knows bugs,<br>
so that it should pass on both (but it still loudly complains about<br>
the bugs).<br>
This is intended to allow to check that the test itself is correct,<br>
until an actually conformant implementation becomes available.<br>
<br>
Note that the nVidia driver was tested on nv40, and the situation<br>
might be better on nv50 and Fermi.<br>
The ATI driver was instead tested on Cypress, and thus is most likely<br>
broken on all cards.<br>
<br>
The main (and essentially only) feature of this extension is the<br>
ability to control clamping to [0, 1] in several places.<br>
This is really tricky to get right (as ATI and nVidia&#39;s failure to do<br>
so shows), and thus the test tries a lot of variations to try to<br>
maximize confidence in the correctness of an implementation.<br>
<br>
It would be nice to test that the alpha test and polygon smoothing are<br>
correct too (i.e. they happen after fragment clamping and before blend<br>
clamping, if any), and improvements in this direction would be<br>
welcome.<br>
Tests for other target formats would also be nice to have, especially<br>
for different cases like unnormalized integer and unsigned floating<br>
point.<br>
<br>
The test is somewhat preliminary and could use some code cleanups, as<br>
well as testing on i965, r300, r500, nv50, Fermi with the proprietary<br>
drivers.<br>
Also having a conformant implementation would help in making sure the<br>
test is really correct: for now testing on both nVidia and ATI drivers<br>
kind of approximates that.<br>
<br>
It includes relevant quotes from the specification, which I believe is<br>
OK under fair use and the fact that it&#39;s available on a public server<br>
anyway. They can be easily removed if desired.<br>
<br>
Is this OK for inclusion?<br>
</blockquote>
<br></div></div>
In addition to Vinson&#39;s comment, I&#39;d suggest breaking up the test() function into smaller, simpler functions to aid debugging.<br>
<br>
Also, I think printf() calls should only be made when there&#39;s an error or when not running in -auto mode.  Otherwise, any unexpected output would be seen as an error (IIRC).<br></blockquote></div><br>stdout is ignored and tests with unignored stderr messages have the &quot;warn&quot; status, which means &quot;pass&quot; but there is some stuff in stderr. printf is a nice way to say what subtest is being run (see e.g. draw-vertices), so that you can easily assign failed pixels to a subtest.<br>

<br>Concerning the test, I&#39;d rather follow the GL specification and ignore that proprietary drivers fail. I am starting to think that ATI/NVIDIA don&#39;t have their internal test suite like we have piglit.<br><br>Marek<br>