The MAGGLASSDATA structure specifies options for the magnifying glass.
typedef struct _tagMAGGLASSDATA
} MAGGLASSDATA, * pMAGGLASSDATA;
The width of the magnifying glass. Minimum size is 10 pixels.
The height of the magnifying glass. Minimum size is 10 pixels.
The zoom factor for the Magnification, in percentage. This value must be >= 100. For example, to zoom the image 2X, specify 200 for nZoom.
The color for the border of the magnifying glass.This is ignored when bEllipse = FALSE and b3D = TRUE.
The color to use for painting areas not covered by the zoomed image. (i.e. When the magnifying glass is not completely over the image.)
Flag that indicates the shape of the magnifying glass. Possible values are:
|TRUE||The magnifying glass is an Ellipse|
|FALSE||The magnifying glass is a Rectangle|
The size of the magnifying glass border in pixels. This value is ignored when bEllipse = FALSE and b3D = TRUE. In this case the magnifying glass appears as a rectangle with a 3D border. The 3D border has a thickness of 2 pixels, one pixel for the highlight color and one for the shadow color.
Flag that indicates whether the border of a rectangular magnifying glass appears as 3D or flat. This value is valid only if bEllipse is FALSE. Possible values are:
|TRUE||The rectangular magnifying glass appears with a 3D border.|
|FALSE||The rectangular magnifying glass appears with a flat border.|
Handle to a custom cursor to use for the Magnify Glass procedure. Pass NULL to use the default cursor.
When bEllipse = TRUE, the default cursor will be:
When bEllipse = FALSE, the default cursor will be:
Flags that indicate how the zoomed image will be painted. These are the same as Flags for the LBitmapWindow::SetDisplayMode function. You can pass 0 to use the current DisplayMode settings. Or, You can specify all the flags you wish to use. If uPaintFlags != 0, then This function will turn off all flags before setting the values you specify. For example, you can use DISPLAYMODE_BICUBIC to make the zoomed image look better.
Optional array of color values to mask out of the Magnified display.
Number of colors in the pMask array.
Value that indicates the type of crosshair to use. Possible values are:
|CROSSHAIR_NONE|| No crosshair in the magnifying glass.|
|CROSSHAIR_FINE|| The crosshair is one pixel wide and is the color of clrPen.|
|CROSSHAIR_INVERTPEN|| The crosshair is three pixels wide. The center pixel is the color of clrPen and the outer pixels are the inverse of clrPen.|
|CROSSHAIR_INVERTSCREEN|| The crosshair is three pixels wide. The center pixel is the color of clrPen and the outer pixels are the inverse of the screen color.|
Flag that indicates whether to magnify only the region in the source bitmap, or to ignore it. Possible values are:
|TRUE||Ignore any existing regions within the source bitmap.|
|FALSE||Magnify only the region within the source bitmap. Data outside the region will be replaced with the color in clrBack.|
Flag that indicates how to center the magnified area. Possible values are:
|TRUE||The zoomed rectangle is centered on the center of the pixel at the center of the magnifying glass.|
|FALSE||The zoomed rectangle is centered on the top, left corner of the pixel at the center of the magnifying glass.|
To use the magnifying glass,
The appearance of the magnifying glass depends on the values of bEllipse, clrPen, b3D and nBorderSize. This can be seen in the table below:
|TRUE||ignored||valid||valid||An elliptical magnifying glass of border size nBorderSize and border color clrPen.|
|FALSE||FALSE||valid||valid||A rectangular magnifying glass with a flat border of width nBorderSize and border color clrPen.|
|FALSE||TRUE||ignored||ignored||A rectangular magnifying glass with a 3D border having a set width and color.|
The structure is used by:
Medical Web Viewer .NET
.NET, Java, Android, and iOS/macOS Assemblies
C API/C++ Class Libraries