[PATCH 1/4] d3d9/tests: Add a windowed GetFrontBufferData test.
stefandoesinger at gmail.com
Wed Jul 15 06:58:38 CDT 2015
-----BEGIN PGP SIGNED MESSAGE-----
Am 2015-07-15 um 13:23 schrieb Henri Verbeet:
> I didn't review the entire set, but that's a problem. I think
> flip_surface() is incredibly ugly, fragile and probably broken in
> some way. I would very much like it to go away, so I don't think
> anything that expands its usage is much of an improvement.
> ddraw_surface7_Flip() doesn't exactly make me happy either, but at
> least it only swaps complete surfaces and views, instead of
> depending on all kinds of wined3d internals. Not invalidating
> basically everything is probably a good thing too.
Yeah, it's ugly, but in the patchset I kept it for now because there
are plenty of other problems to solve as well. How we flip the
surfaces or surface contents is fairly easy to separate from the rest
of the issues we need to fix.
One idea would be to swap the swapchain resource pointers (and render
target views if one of the buffers is currently assigned) and have a
callback that tells the client libraries to re-fetch the wined3d
objects for its front and back buffers. The lucky part is that render
targets aren't stored in stateblocks in d3d8/9. I have done absolutely
no investigation how well this would work with d3d10/11 yet. The
expected problem is that in d3d10 the swapchain textures can be part
of any number of views and they all need to be updated.
I don't think controlling everything from the client library (the
current ddraw_surface7_Flip way) works without having the shadowfb in
the client library as well.
The other option would be to restructure the FBO cache to store GL
textures instead of surfaces to make the GL texture swapping scheme
more efficient. That won't fix the remaining ugliness of flip_surface
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
-----END PGP SIGNATURE-----
More information about the wine-devel