25 Nov
2013
25 Nov
'13
4:16 p.m.
On 25 November 2013 14:22, Henri Verbeet <hverbeet(a)gmail.com> wrote:
On 25 November 2013 13:47, Stefan Dösinger <stefandoesinger(a)gmail.com> wrote:
Why not something like
if (surface->flags & SFLAG_INSYSMEM) surface_invalidate_location(surface, ~SFLAG_INSYSMEM);
If the surface doesn't have SFLAG_INSYSMEM set already downloading texture / framebuffer data to sysmem and re-uploading it won't do anything.
That's probably ok, but I don't think it should necessarily go into this patch. Actually, would that do that right thing if the application first calls AddDirtyRect(), and then LockRect() with D3DLOCK_DISCARD | D3DLOCK_NO_DIRTY_UPDATE?