To learn more about how DirectDraw can be used in applications, you should check out some of the other following samples included with the DirectX SDK:
·Stretch
Demonstrates how to create a nonexclusive (windowed) mode animation in a window that is capable of clipped blitting and stretched-clipped blitting.
·Donut
Demonstrates testing multiple exclusive-mode applications interacting with nonexclusive-mode applications.
·Wormhole
Demonstrates palette animation.
·Dxview
Demonstrates how to retrieve the capabilities of the display hardware.
Other samples you can examine for their DirectDraw code include Duel, Iklowns, Foxbear, Palette, and Flip2d.