[PATCH] wined3d: Fix ATI1 buffer size, try 2

Henri Verbeet hverbeet at gmail.com
Wed Aug 24 05:45:51 CDT 2016


On 22 August 2016 at 18:53, Patrick Rudolph <siro at das-labor.org> wrote:
> Apitrace crashes on WINE when trying to playback a trace containing ATI1 textures.
>
> Add a tests to show that "unknown" formats like ATI1 are backed by a buffer
> of size pitch * height. Without the attaced fix the tests will crash.
>
> Calculate correct buffer size in wined3d_format_calculate_pitch for formats that
> have WINED3DFMT_FLAG_BROKEN_PITCH flag set.
> Remove no longer needed check in texture_resource_sub_resource_map.
>
> Signed-off-by: Patrick Rudolph <siro at das-labor.org>
> ---
>  dlls/d3d9/tests/device.c |  8 ++++++++
>  dlls/wined3d/texture.c   | 10 +---------
>  dlls/wined3d/utils.c     |  9 ++++++++-
>  3 files changed, 17 insertions(+), 10 deletions(-)
>
This breaks the tests. For example:

    ../../../tools/runtest -q -P wine -T ../../.. -M d3d9.dll -p
d3d9_test.exe.so visual && touch visual.ok
    visual.c:9512: Tests skipped: Card has unconditional NP2 support,
skipping conditional NP2 tests
    visual.c:13651: Tests skipped: No NVDB (depth bounds test)
support, skipping tests.
    visual.c:17111: Tests skipped: DXT5 volume textures are not
supported, skipping test.
    visual.c:17966: Test failed: Got unexpected color 0x008080ff, case 2.
    visual.c:17966: Test failed: Got unexpected color 0x008080ff, case 3.
    visual.c:19801: Tests skipped: Volume ATI2N textures are not
supported, skipping some tests.
    Makefile:276: recipe for target 'visual.ok' failed
    make: *** [visual.ok] Error 2



More information about the wine-devel mailing list