Thanks for the review.
They fail on my Windows XP box, r250 GPU, see the attached log file. It seems that It doesn't follow the alpha = 0xff behavior of newer GPUs and just returns alpha 0x0 in either case. The window positioning test needlessly depends on it. If I mask out the alpha channel in test_get_front_buffer_data_windowed_positioning() it passes.
Interesting. I'd be perfectly fine with dropping the separate alpha test entirely. I also meant to mask out the alpha but I guess I forgot it there or lost it during rebase/cleanup.
if (foo) { something(); }
Please put the { on a new line consistently.
Ah, I'm trying. I thought I got it right but I guess old habits die hard. I use the same line { in every other project, so not surprised that I slipped up a couple of times. I'll fix that.
test_swapchain_buffer_swapping() and test_get_front_buffer_data_alpha() leak your initial device, the one you use to populate present_parameters
In the case of test_swapchain_buffer_swapping I don't see why you need to call IDirect3D9::CreateDevice yourself - what prevents you from using the device returned by create_device?
Oops, that's a leftover of my original approach. I originally meant to create a new device for each test case and pass the required presentation params but later changed it to just use a single device created using `create_device` and reset that as needed. I meant to get rid of the second device that's created manually.
I will also look into using the current monitor resolution for the fullscreen tests.