Share via


DDGPESurf Class Definition (Windows CE 5.0)

Send Feedback

The DDGPESurf class extends the GPESurf class. It also represents a surface, which might have been allocated by GDI, the display driver, or the DDHAL. DDGPESurf objects are typically created for all surfaces.

DDGPESurf (
int width,
int height,
void *pBits,
int stride,
EGPEFormat format
);
DDGPESurf (
int width,
int height,
void *pBits,            
int stride,
EGPEFormat format,
EDDGPEPixelFormat pixelFormat
);
DDGPESurf (
int width,
int height,
int stride,
EGPEFormat format,
EDDGPEPixelFormat pixelFormat
);
DDGPESurf (
int width, 
int height,
EGPEFormat format
);

// Initialization
virtual void Init (
int width,
int height,
void *pBits,
int stride,
EGPEFormat format,
EDDGPEPixelFormat pixelFormat
);

// Get and set associated DirectDraw surfaces
virtual LPDDRAWI_DDRAWSURFACE_LCL
 GetDirectDrawSurface (
void
);
virtual void SetDirectDrawSurface (
LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
);

// Attach GPE surface to DirectDraw surface
virtual void SetDDGPESurf(
LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
);

// Surface information
virtual DWORD Bpp (
void
);
virtual DWORD AlignedWidth (
void
);

virtual void SetColorKey (
DWORD dwColorKey
);
virtual DWORD ColorKey (
void
);
virtual void SetColorKeyMask (
DWORD dwColorKeyMask
);
virtual DWORD ColorKeyMask (
void
);

virtual void SetColorKeyLow (
DWORD dwColorKey
);
virtual DWORD ColorKeyLow (
void
);
virtual void SetColorKeyHigh (
DWORD dwColorKey
);
virtual DWORD ColorKeyHigh(
void
);

virtual EDDGPEPixelFormat
 PixelFormat (
void
);

virtual BOOL HasAlpha (
void
);

// Custom driver data
virtual DDGPEDriverData*
 GetDriverData (
void
);

virtual void SetDriverData (
DDGPEDriverData*pDriverData
);

// Custom driver identifier
virtual GUID GetDriverGUID (
void
);
virtual void SetDriverGUID (
GUID guidDriverGUID
);


// Surface operations
static void DeleteSurface (
LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
);
static DDGPESurf*
 GetDDGPESurf (
LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface
);
static void Swap (
LPDDRAWI_DDRAWSURFACE_LCL s1,
LPDDRAWI_DDRAWSURFACE_LCL s2
);

protected:
DWORD m_dwColorKeyLowValue;
DWORD m_dwColorKeyHighValue;
DWORD m_dwColorKeyMask;
EDDGPEPixelFormat m_ePixelFormat;

public:
LPDDRAWI_DDRAWSURFACE_LCL lpDDSurface;
 
// a place for drivers to store their data
DDGPEDriverData*m_pDriverData;
GUID m_guidDriverGUID;

See Also

DDGPESurf Class

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.