static const
Done
We should instead use compare_color(..., 1),
Oh, I didn't know about this one. Thank-you. I had considered writing something like this myself, so very happy to find it already exists.
Which ones?
Good question. I'm not 100% where the implementation exists. It might be a hardware vs. software thing and/or possibly the graphics driver. But I discovered this when running the tests on testbot (on my Windows install it uses the HD values).
can we change these values to be, say, 576 and 572
I used 576 and 580 (otherwise they're both SD).
hr == S_OK
Done
we can move the surface creation to the outer loop, right?
Not quite, as we resize during the inner loop. But I did modify it to only recreate the surface if a resize is required. I could also separate the SD and HD tests, that way we'd only create the RGB texture twice instead of eight times. Let me know if you think that's worth it.
We have winetest_push_context() now; let's use that in new code
I knew about that one, I should have used it.
Also, specifying both an index and a name seems a bit redundant?
Agreed
A skip in that case seems odd, why not just use broken() when comparing colours?
Good point. I think I originally missed the difference, but if I understand correctly: a `skip` will skip the tests on Wine, where as a `broken` only applies to Windows. Is that right?
it seems this could be a regular todo_wine
Some tests actually pass with the current implementation, so I do need a `todo_wine_if`.
We're dealing with floats here, though, not integers. Also, as the tests show, being off by one isn't really a problem
Yeah, fair enough. I think I got caught up with making sure my results on Wine matched exactly with on the results on my Windows install. But after testing with testbot, it's evident that an off-by-one is pretty standard. I've changed that.