MapWindowPoints
The MapWindowPoints
function converts (maps) a set of points from a coordinate space relative to
one window to a coordinate space relative to another window.
int MapWindowPoints(
HWND hWndFrom, |
// handle of window
to be mapped from |
HWND hWndTo, |
// handle of window
to be mapped to |
LPPOINT lpPoints, |
// address of
structure array with points to map |
UINT cPoints |
// number of
structures in array |
); |
|
Parameters
hWndFrom
Identifies
the window from which points are converted. If this parameter is NULL or
HWND_DESKTOP, the points are presumed to be in screen coordinates.
hWndTo
Identifies
the window to which points are converted. If this parameter is NULL or
HWND_DESKTOP, the points are converted to screen coordinates.
lpPoints
Points to an
array of POINT
cPoints
Specifies the
number of POINT structures in the array pointed to by the lpPoints
parameter.
Return Values
If the
function succeeds, the low-order word of the return value is the number of
pixels added to the horizontal coordinate of each source point in order to
compute the horizontal coordinate of each destination point; the high-order
word is the number of pixels added to the vertical coordinate of each source
point in order to compute the vertical coordinate of each destination point.
See Also