d3dx9: Implement D3DXFloat32To16Array and D3DXFloat16To32Array. (try 2)
kgbricola at web.de
Mon Feb 21 14:59:50 CST 2011
Am 21.02.2011 20:19, schrieb Misha Koshelev:
> Thanks Rico.
> Still trying to investigate this further.
> Perhaps, if you have any more hints as to how you arrived at this
> magical value, much appreciated.
I got to this value by running the attached test patch applied after
yours. You probably may
modify the for loop. I've chosen the increment because of time/usage.
You may try with 0xff or a lower value instead of 0xfff, but be warned
running at 1 will take a
while to see a failed test.
You need a copy of native d3dx9_36.dll renamed to d3dx9_36_2.dll in the
path. The test
should show the difference between native and wine's implementation. I
haven't run the test
on windows, yet.
> Namely, at first my hunch was that this value (2.9806e-08 with the
> following bitwise representation):
> 0 01100110 00000000000010000000000
> was simply being truncated to the smallest denormalized value
> representable by a half precision float:
> 0 000.00 00.0000.0001 6×10-8 (Smallest denormalized value)
> but this is clearly not true for other values that are too small (they
> are returned as 0.0f).
I haven't had the time to investigate this completely, yet. But probably
there are a couple of values
produced by the patch which should give a hint to what bits are
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the wine-devel