DWORD GetRegionData(hRgn, nCount, lpRgnData) | |||
HRGN hRgn; | |||
DWORD nCount; | |||
LPRGNDATA lpRgnData; |
The GetRegionData function fills a buffer with the data that defines the region specified by the hRgn parameter. The region coordinates are returned in lpRgnData. nCount is the size of the buffer. It must be large enough to hold all the region data or an error is returned.
hRgn
Identifies the region.
nCount
Specifics the size of the lpRgnData buffer in bytes.
lpRgnData
Points to a RGNDATA structure that is to receive the information. If NULL, then the return value contains the number of bytes needed for the region data.
The function returns 1 if successful and zero for error. If nCount is too small for the data or lpRgnData is NULL then the call returns the number of byte required to hold the region data. Since the data is always larger than one byte it is possible to distinguish between success and buffer too small conditions.
This function is used in conjunction with the ExtCreateRegion calls. Use GetRegionData to fill in the REGIONDATA structure. Use ExtCreateRegion to recreate the region.
ExtCreateRegion