DDSCAPS (Compact 2013)

3/26/2014

This structure defines the capabilities of a DirectDrawSurface object. This structure is part of the DDCAPS and DDSURFACEDESC structures.

Syntax

typedef struct _DDSCAPS{ 
  DWORD dwCaps; 
} DDSCAPS, FAR* LPDDSCAPS; 

Members

  • dwCaps
    Capabilities of the surface. The following table shows the possible flags.

    Flag

    Description

    DDSCAPS_ALPHA

    Indicates that this surface contains alpha-only information.

    DDSCAPS_BACKBUFFER

    Indicates that this surface is the back buffer of a surface flipping structure.

    Typically, this capability is set by the CreateSurface method when the DDSCAPS_FLIP flag is used.

    Only the surface that immediately precedes the DDSCAPS_FRONTBUFFER surface has this capability set.

    The other surfaces are identified as back buffers by the presence of the DDSCAPS_FLIP flag, their attachment order, and the absence of the DDSCAPS_FRONTBUFFER and DDSCAPS_BACKBUFFER capabilities.

    If this capability is sent to the CreateSurface method, a stand-alone back buffer is being created.

    After this method is called, this surface could be attached to a front buffer, another back buffer, or both to form a flipping surface structure.

    DDSCAPS_DYNAMIC

    Unsupported.

    DDSCAPS_FLIP

    Indicates that this surface is a part of a surface flipping structure.

    When this capability is passed to the CreateSurface method, a front buffer and one or more back buffers are created.

    DirectDraw sets the DDSCAPS_FRONTBUFFER bit on the front-buffer surface and the DDSCAPS_BACKBUFFER bit on the surface adjacent to the front-buffer surface.

    The dwBackBufferCount member of the DDSURFACEDESC structure must be set to at least 1 for the method call to succeed.

    DDSCAPS_FRONTBUFFER

    Indicates that this surface is the front buffer of a surface flipping structure.

    This flag is typically set by the CreateSurface method when the DDSCAPS_FLIP capability is set.

    If this capability is sent to the CreateSurface method, a stand-alone front buffer is created.

    This surface will not have the DDSCAPS_FLIP capability.

    DDSCAPS_NOTUSERLOCKABLE

    Unsupported.

    DDSCAPS_OVERLAY

    Indicates that this surface is an overlay.

    It may or may not be directly visible depending on whether it is currently being overlaid onto the primary surface.

    DDSCAPS_VISIBLE can be used to determine if it is being overlaid at the moment.

    DDSCAPS_PALETTE

    Not supported.

    DDSCAPS_PRIMARYSURFACE

    Indicates the surface is the primary surface.

    It represents what is seen by the user at the moment.

    DDSCAPS_READONLY

    Indicates that only read access is permitted to the surface. When locking the surface with IDirectDrawSurface::Lock, the DDLOCK_READONLY flag must be specified.

    DDSCAPS_SYSTEMMEMORY

    Indicates that this surface memory was allocated in system memory.

    DDSCAPS_VIDEOMEMORY

    Indicates that this surface exists in display memory.

    DDSCAPS_WRITEONLY

    Indicates that only write access is permitted to the surface.

    Read access from the surface may generate a general protection (GP) fault, but the read results from this surface will not be meaningful.

Requirements

Header

ddraw.h

See Also

Reference

DirectDraw Structures
DirectDraw Reference

Other Resources

DirectDraw