HRESULT CreateSurface(LPDDSURFACEDESC lpDDSurfaceDesc,
LPDIRECTDRAWSURFACE FAR * lplpDDSurface,
IUnknown FAR * pUnkOuter);
Creates a DirectDrawSurface object for this DirectDraw object.
·Returns DD_OK if successful, or one of the following error values otherwise:
DDERR_PRIMARYSURFACEALREADYEXISTS
lpDDSurfaceDesc
Address of the DDSURFACEDESC structure that describes the requested surface.
lplpDDSurface
Address of a pointer to be initialized with a valid DirectDrawSurface pointer if the call succeeds.
pUnkOuter
Allows for future compatibility with COM aggregation features. Presently, however, IDirectDraw2::CreateSurface returns an error if this parameter is anything but NULL.