| Customize Help
| Save Settings

MdispSelect



Function Map
Synopsis
Select an image buffer to display.
Syntax
void MdispSelect(
MIL_ID DisplayId, //in
MIL_ID ImageBufId //in
)
Description

This function outputs the content of the specified image buffer to the specified MIL display. You can only display one image buffer at a time on a specific display.

For a windowed display, the image is presented in a window that has the same size as the image, unless such a window would not fit on the desktop or would be too small. If the image is too large to fit in the largest possible window given the selected display resolution, the top-left corner of the image will be aligned with the top-left corner of the largest possible window, and the right and bottom portion of the image, the part that exceeds the window area, will not be displayed; to view the missing portions of the image, you can pan the displayed image (see the Panning and zooming section of Chapter 23: Displaying an image for more information). If the image is smaller in size than the smallest possible window, the image will be centered in the smallest possible window, and the surrounding area will be filled with the background color (MdispControl() with M_BACKGROUND_COLOR). If the window is enlarged or maximized, the image will remain the same size and centered.

For an exclusive display, the image is presented full-screen, without a windowed border or frame, on one of the Windows desktop screens. The image is presented at the center of the screen. If the image is too large to fit on screen given the selected display resolution, the top-left corner of the image will be aligned with the top-left corner of the screen, and the right and bottom portion of the image, the part that exceeds the screen area, will not be displayed; to view the missing portions of the image, you can pan the displayed image (see the Panning and zooming section of Chapter 23: Displaying an image for more information). If the image is smaller in size than the screen area, the image will be centered on screen, and the surrounding area will be filled with the background color (MdispControl() with M_BACKGROUND_COLOR).

For a MILweb display, the image is presented in one or more connected instances of a MILweb client application (typically running on a remote computer). The size of the transmitted display is the same as the size of the image buffer. If the displayed image is panned or zoomed (see the Panning and zooming section of Chapter 23: Displaying an image for more information) so that it does not fill the display, the surrounding area will be filled with the background color (MdispControl() with M_BACKGROUND_COLOR). The MILweb client application might further crop or scale the displayed image after it is transmitted.

You can control the displayed area using MdispControl(), MdispPan(), or MdispZoom(). For example, you can center the selected image in the display using MdispControl() with M_CENTER_DISPLAY.

You can remove an image buffer selected to the display using MdispSelect() with M_NULL. For windowed displays, this closes the associated window. For exclusive displays, this causes the display to disappear, allowing the desktop to reappear on the screen.

You can only remove the entire image buffer from the display. Therefore, when displaying a parent buffer, you cannot remove one of its child buffers from the display.

Note that it is not necessary to stop displaying the image buffer before selecting another buffer for display.

You can annotate the image selected to the display non-destructively using the display's overlay mechanism (MdispControl() with M_OVERLAY) or using a 2D graphics list (MdispControl() with M_ASSOCIATED_GRAPHIC_LIST_ID). The display's overlay mechanism allows you to annotate the selected image using an automatically allocated, temporary, image buffer referred to as the display's overlay buffer; you can modify the overlay buffer with any function that writes to an image buffer (except a grabbing function). Annotating with a 2D graphics list allows you to annotate the selected image with the vector-based graphics in the 2D graphics list; you can add vector-based graphics to the 2D graphics list using Mgra...() and M...Draw() functions. Annotating using the latter technique avoids pixelization when the display is zoomed since the graphics are in vector format. For more information on non-destructive annotation see the Annotating the displayed image non-destructively section of Chapter 23: Displaying an image.

If the selected image is calibrated, the image is not physically corrected on display. If the display is associated with an overlay buffer (MdispControl() with M_OVERLAY), the camera calibration information of the selected buffer is copied to the overlay buffer; this allows you to draw in the overlay buffer in world units. If the camera calibration information of the overlay buffer is modified using McalAssociate(), MbufClear(), or some other function, the camera calibration information of the selected buffer will not be updated accordingly. However, changing the camera calibration information of the selected buffer will re-copy the camera calibration information of the selected buffer to the overlay buffer, even if the camera calibration information of the overlay buffer was manually changed.

Note that this function reference has not been updated for a MIL system added during a MIL update. Refer to the MIL system's release note to see which MIL system’s documentation you should use in its place and any possible differences.
Parameters
This function is not supported on the selected boards.
This function reference has not been updated for the selected MIL system. To show the content of this page, choose a second MIL system; refer to the MIL system's release note to see which MIL system’s documentation to choose and any possible differences.
Parameters
DisplayId

Specifies the identifier of the display.

ImageBufId

Specifies the identifier of the image buffer to display. To be displayable, this buffer must be an image buffer that has an M_IMAGE + M_DISP attribute.

Set this parameter to M_NULL to stop displaying the currently selected image buffer on the specified display.

Note that the image buffer and the display should be allocated on the same system.

Compilation information
Header Include mil.h.
Library Use mil.lib.
DLL Requires mil.dll; mildisplay.dll.
DISP