[3/7] d3d9/tests: Add a test for locking partial blocks (try 2)

Stefan Dösinger stefan at codeweavers.com
Tue Oct 18 12:36:33 CDT 2011


On Tuesday 18 October 2011 17:37:09 Henri Verbeet wrote:
> That's not really what I meant with "make this part of the test in
> patch 3/7". The point is that test_lockrect_offset() is about the
> offset calculation, not so much about what valid rectangles for block
> based formats are. And it probably wouldn't hurt to run
> test_partial_block_lock() on the other formats like e.g. ATI2N anyway.
I felt that merging the tests to test all format and pool combinations would 
cause needlessly complicated code because some format-pool combinations 
require surfaces, some require dynamic textures, some require normal textures 
and some are unsupported. That's why I introduced the new test that loops only 
over the pools.

On the other hand we may at some point care about the offset returned by a 
allowed partial block lock, which is why putting the per-format test in 
test_partial_block_lock correct imo. Strictly speaking the test now verifies 
the block sizes directly instead of just verifying them indirectly as a side 
product of testing the stride, so we might as well rename it.

ATI2N is a good point though. The locking behavior matches the 1x1 "block" 
definition in the d3d9 test. I'll change the test to verify that we can indeed 
lock single pixels in formats that are supposedly block-free(and that we can 
lock single lines in YUY2/UYVY)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://www.winehq.org/pipermail/wine-devel/attachments/20111018/f90edb53/attachment.pgp>


More information about the wine-devel mailing list