IDXSurface interface
The IDXSurface interface is used to access DXSurface objects, which store images.
Members
The IDXSurface interface inherits from IDXBaseObject. IDXSurface also has these types of members:
- Methods
Methods
The IDXSurface interface has these methods.
Method | Description |
---|---|
GetAppData | Retrieves an application-specific DWORD of data. |
GetBounds | Retrieves a structure that contains the surface's boundary region. |
GetColorKey | Retrieves the surface's color key value. |
GetDirectDrawSurface | Retrieves an interface on the underlying IDXSurface::GetDirectDrawSurface object if the DXSurface object is aggregated onto a IDXSurface::GetDirectDrawSurface. |
GetPixelFormat | Retrieves the pixel format of the surface. |
GetStatusFlags | Retrieves the status flags of the DXSurface object. |
LockSurface | Locks a region of the surface and returns a pointer through which you can access samples on DXSurfaces. |
LockSurfaceDC | Locks a region of the surface and returns an IDXDCLock interface. |
SetAppData | Sets the surface's application-specified DWORD of data. |
SetColorKey | Sets the surface's color_key value. |
SetStatusFlags | Sets the status flags of the DXSurface object. |
Remarks
The interface is supported by objects that wrap traditional bitmap memory arrays, as well as objects that produce images procedurally. DXSurface objects are created through the IDXSurfaceFactory interface. Other objects, such as procedural surfaces, can implement the IDXSurface interface to act as image objects.
The basic bitmap object is exposed by DXSurface objects, which have a class identifier (CLSID) of CLSID_DXSurface. These DXSurfaces wrap DirectDrawSurface objects or can be used to perform operations directly on memory buffers.
This interface provides methods for determining information about surfaces, such as the native pixel format and bounds. The IDXSurface interface also is used to lock the surface to provide access to the samples or to a handle to a device context.
You can implement this interface when you are creating a custom surface. You must reimplement this interface to support new pixel formats that are introduced. If you want to introduce a new pixel format, you must implement the DXSurface object with the support for the new pixel format. For a list of supported pixel formats, see Supported Pixel Formats.
Other objects can implement the IDXSurface to act as an image object. Objects of this type are typically referred to as procedural surfaces because they produces data on request. Two examples of procedural surfaces are gradient fills and surface modifiers.
This interface inherits from the IDXBaseObject interface.
Requirements
Minimum supported client |
Windows XP |
Minimum supported server |
Windows 2000 Server |
Header |
Dxtrans.h |
IDL |
Dxtrans.idl |
DLL |
Dxtrans.dll |