[3/5] WineD3D: Avoid double buffered dynamic buffers

Stefan Dösinger stefan at codeweavers.com
Mon Jan 4 12:50:45 CST 2010


Currently we're using glBufferSubData() in PreLoad, which doesn't have the ability to handle D3DLOCK_NOOVERWRITE in either extension. Thus this is a mayor performance hit because PreLoad cannot complete until drawing has finished.

PreLoad could of course use MapBuffer instead, but this would add an additional copy(inside opengl), so we have two copy operations, and I don't expect this to be a net performance gain over plain sysmem draws.

When is this relevant: Double buffering is used with buffer conversion, or if draws with stride 0 happen(static GL attribute) or instanced draws are done. The first situation never happens with dynamic buffers(already filtered), but the other two are still possible.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0003-WineD3D-Avoid-double-buffered-dynamic-buffers.txt
URL: <http://www.winehq.org/pipermail/wine-patches/attachments/20100104/114df8e6/attachment.txt>


More information about the wine-patches mailing list