DSurface optimization, comments requested

Aric Stewart aric at codeweavers.com
Fri Jul 25 05:24:50 CDT 2008

Hi there,

I was playing with a older Japanese side scrolling shooter benchmark and 
was getting 4.3 frames per second. Some digging revealed that the game 
made extensive use of Blt on gdi surfaces and it looks like the current 
implementation of Blt actually locks the entire destination surface to 
blt to it. This then causes the Unlock to copy the entire screen out. 
This means that every time any sprite moved the entire screen redrew.

I threw together this patch, which seems far to simple to be at all 
correct, and suddenly i was getting 28.8 frames per second. I know it is 
not fully correct because a a portion of the game (drawn by FastBlt it 
looks like) stopped rendering correctly with this patch.

But I thought it may get someone who knows that area better thinking 
about it. If we can optimize this then a number of the scrolling shooter 
games will become playable. I am told that these style games are still 
very popular here.

And if said people in the know where to busy, maybe they could give me 
some pointers on if I have the right approach or not.

If anyone is interested I can provide an archive with the benchmark 
program in it.

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: dsurface.diff
Url: http://www.winehq.org/pipermail/wine-devel/attachments/20080725/e4976839/attachment.txt 

More information about the wine-devel mailing list