<p dir="ltr">Yeah, I'm OK with this too.  At some point it would be good to put a lite effort into making both formulas valid so that piglit works on both legacy and post 3.2 contexts.  But that's more of a to do list item than a comment on this patch.<br>
--Jason</p>
<div class="gmail_quote">On Sep 25, 2014 3:21 PM, "Brian Paul" <<a href="mailto:brianp@vmware.com">brianp@vmware.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 09/25/2014 03:56 PM, Anuj Phogat wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Thu, Sep 25, 2014 at 6:52 AM, Brian Paul <<a href="mailto:brianp@vmware.com" target="_blank">brianp@vmware.com</a>> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Use Mesa's UBYTE_TO_FLOAT_TEX() arithmetic.  This lets Mesa pass the<br>
</blockquote>
I think you mean BYTE_TO_FLOAT_TEX() here.<br>
</blockquote>
<br>
Yes, thanks.  I'll fix that.<br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
test.  No regression with nvidia's driver either.<br>
---<br>
  tests/general/draw-pixels.c |    2 +-<br>
  1 file changed, 1 insertion(+), 1 deletion(-)<br>
<br>
diff --git a/tests/general/draw-pixels.c b/tests/general/draw-pixels.c<br>
index 27b1675..65f5122 100644<br>
--- a/tests/general/draw-pixels.c<br>
+++ b/tests/general/draw-pixels.c<br>
@@ -37,7 +37,7 @@<br>
  #define UBYTE_TO_FLOAT(u) ((float) u / 255.0F)<br>
<br>
  /** Convert GLbyte in [-128,127] to GLfloat in [-1.0,1.0] */<br>
-#define BYTE_TO_FLOAT(B)    ((2.0F * (B) + 1.0F) * (1.0F/255.0F))<br>
+#define BYTE_TO_FLOAT(B)    ((B) == -128 ? -1.0F : (B) * (1.0F/127.0F))<br>
<br>
  /** Convert GLushort in [0,65535] to GLfloat in [0.0,1.0] */<br>
  #define USHORT_TO_FLOAT(S)  ((GLfloat) (S) * (1.0F / 65535.0F))<br>
--<br>
1.7.10.4<br>
<br>
______________________________<u></u>_________________<br>
Piglit mailing list<br>
<a href="mailto:Piglit@lists.freedesktop.org" target="_blank">Piglit@lists.freedesktop.org</a><br>
<a href="https://urldefense.proofpoint.com/v1/url?u=http://lists.freedesktop.org/mailman/listinfo/piglit&k=oIvRg1%2BdGAgOoM1BIlLLqw%3D%3D%0A&r=lGQMzzTgII0I7jefp2FHq7WtZ%2BTLs8wadB%2BiIj9xpBY%3D%0A&m=ohKLzWSFy4um%2FbQz3pESy2HCK32TcqIlTx2AShS5cEk%3D%0A&s=d3673b4789b125e183860b156956ea907d63e764103fff30ea8f48fee26dae0d" target="_blank">https://urldefense.proofpoint.<u></u>com/v1/url?u=http://lists.<u></u>freedesktop.org/mailman/<u></u>listinfo/piglit&k=oIvRg1%<u></u>2BdGAgOoM1BIlLLqw%3D%3D%0A&r=<u></u>lGQMzzTgII0I7jefp2FHq7WtZ%<u></u>2BTLs8wadB%2BiIj9xpBY%3D%0A&m=<u></u>ohKLzWSFy4um%<u></u>2FbQz3pESy2HCK32TcqIlTx2AShS5c<u></u>Ek%3D%0A&s=<u></u>d3673b4789b125e183860b156956ea<u></u>907d63e764103fff30ea8f48fee26d<u></u>ae0d</a><br>
</blockquote>
<br>
Both patches are:<br>
Reviewed-by: Anuj Phogat <<a href="mailto:anuj.phogat@gmail.com" target="_blank">anuj.phogat@gmail.com</a>><br>
<br>
</blockquote>
<br>
______________________________<u></u>_________________<br>
Piglit mailing list<br>
<a href="mailto:Piglit@lists.freedesktop.org" target="_blank">Piglit@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/piglit" target="_blank">http://lists.freedesktop.org/<u></u>mailman/listinfo/piglit</a><br>
</blockquote></div>