What Are DirectDraw Objects? (Windows Embedded CE 6.0)

1/6/2010

The DirectDraw object is the heart of all DirectDraw applications. It is the first object you create and, through it, you create all other related objects.

Typically, you create a DirectDraw object by calling the DirectDrawCreate function, which returns an IDirectDraw interface.

The DirectDraw object represents the display device and makes use of hardware acceleration if the display device for which it was created supports hardware acceleration.

Each unique DirectDraw object can manipulate the display device and create surfaces, palettes, and clipper objects that are dependent on (or are, connected to) the object that created them.

For example, to create surfaces, you call the IDirectDraw::CreateSurface method. Additionally, the IDirectDraw interface exposes similar methods to create clipper objects.

The DirectDraw object manages all of the objects it creates. It controls the default palette (if the primary surface is in 8-bits-per-pixel mode), the default color key, and the hardware display mode. It tracks what resources have been allocated and what resources remain to be allocated.

See Also

Concepts

Working with DirectDraw Objects