Products | Support | Send comments on this topic. | Email a link to this topic. | Back to Getting Started | Help Version 18.0.10.24
LEADTOOLS Raster imaging C++ Class library help

Zooming In on a Selection: Step 3

Show in webframe

/* Save the starting position in screen pixels (used by GDI functions) */
StartGDIX = point.x;
StartGDIY = point.y;
/* Use the mouse position's percentage offsets in the image rectangle
to determine the pixel offsets in the bitmap.
Using percentages allows for the possibility that the image is zoomed. */
StartPixelX = MulDiv(LeadBitmap.GetWidth(), StartGDIX - rLeadDest.left, DisplayWidth);
StartPixelY = MulDiv(LeadBitmap.GetHeight(), StartGDIY - rLeadDest.top, DisplayHeight);

/* Initialize a variable used when the WM_MOUSEMOVE event outlines the area */
FirstDraw = TRUE;
 

Products | Support | Contact Us | Copyright Notices
© 2006-2014 All Rights Reserved. LEAD Technologies, Inc.