Article ID: 130805 - Last Review: November 21, 2006 - Revision: 4.4 Drawing to a Memory Bitmap for Faster PerformanceThis article was previously published under Q130805 SUMMARY
An application whose client area is a complex image can realize a
performance benefit from drawing to a memory bitmap. The complex, time
consuming drawing code need only be performed once - to initialize the
offscreen bitmap. During the handling of the WM_PAINT message, the only
work that needs to be done is a simple BitBlt from the memory bitmap to the
screen.
Sample code demonstrating this technique is available in the Microsoft Dowload Center. The MemDC sample code draws a complex pattern on its client area. A menu option toggle allows the user to see the speed difference between using and not using the offscreen bitmap. MORE INFORMATIONThe following file is available for download from the Microsoft Download Center: Memdc.exe
(http://download.microsoft.com/download/platformsdk/file/1.0/win98/en-us/memdc.exe)
For additional information about how to download Microsoft Support files, click the following article number to view the article in the Microsoft Knowledge Base:
119591
(http://support.microsoft.com/kb/119591/EN-US/
)
How to Obtain Microsoft Support Files from Online Services
Microsoft scanned this file for viruses. Microsoft used the most current virus-detection software that was available on the date that the file was posted. The file is stored on security-enhanced servers that help to prevent any unauthorized changes to the file.
APPLIES TO
| Article Translations
|
Back to the top
