ENTER_GL and ActivateContext question
Alexander Dorofeyev
alexd4 at inbox.lv
Sat Dec 15 05:19:36 CST 2007
Hi.
Here's preliminary version of a changes to BltOverride/Clear, with Clear
subroutine approach discussed previously. Please look through it if you can.
Basically everything except a check for error condition and deciding the target
surface moved from Clear to subroutine. Another thing I did is moving code that
does IWineD3DSurface_LoadLocation below the ActivateContext in the subroutine
(originally it was done prior to ActivateContext), because it seems to do GL
calls at least in some codepaths and doesn't seem to do ActivateContext.
Another issue I noticed in tests (seems to be present in wine-0.9.50 too, before
ActivateContext was added to BltOverride) is that BltOverride/colorfill to front
buffer often doesn't actually make filled rectangles appear - they can fail to
appear for indefinite time, especially if there are no subsequent identical or
similar calls, but there are no visible errors in traces. glFlush does make them
appear, so maybe they are somehow getting buffered. This seems to be specific to
front buffer. Maybe glFlush really should be called in BltOverride (or clearing
subroutine) if the target is front buffer?
Stefan Dösinger wrote:
> A last option is to move the biggest part of Clear() into a subroutine, call
> the ActivateContext in Clear and BltOverride, and perform the rest of the job
> in the subroutine. The drawback of this is that d3d8 and d3d9 clears run
> through an extra call, but it avoids the SetRenderTarget/GetRenderTarget
> overhead and direct implementation access. The function could be inlined as
> well, but I am not sure if that works across .c files.
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0001-wined3d-restructure-and-cleanup-colorfill-codepath-in.txt
Url: http://www.winehq.org/pipermail/wine-devel/attachments/20071215/0fd8af01/attachment-0002.txt
More information about the wine-devel
mailing list