MIL_ID SrcListGraId, | //in |
MIL_ID DstListGraId, | //in |
MIL_INT64 Operation, | //in |
MIL_INT InsertLocation, | //in |
MIL_INT NumGraphics, | //in |
const MIL_INT *SrcIndexOrLabelArrayPtr, | //in |
MIL_INT *DstLabelArrayPtr, | //out |
MIL_INT64 ControlFlag | //in |
This function copies or moves one or more graphics from a source 2D graphics list to a destination 2D graphics list. When moved, the graphics are erased from the source 2D graphics list. You can specify the location in the destination 2D graphics list at which to insert the copied graphics, which offers some control on the drawing order.
Note that if you want to replace all existing elements of the destination 2D graphics list, you must clear it first using MgraClear().
This function supports in-place processing: the source and destination 2D graphics list identifiers can refer to the same 2D graphics list. In the case of an in-place move operation (M_MOVE), the graphic referred to by the InsertLocation parameter must not be one of the graphics being moved (SrcIndexOrLabelArrayPtr).
Unlike most other functions that modify a MIL object, you can call this function concurrently from multiple threads on the same MIL 2D graphics list (DstListGraId) without using an M_MUTEX object, as long as all the other parameters of the concurrent calls do not also share data.
Specifies the identifier of a valid 2D graphics list from which to copy or move the graphics. You must have allocated the 2D graphics list using MgraAllocList().
Specifies the identifier of a valid 2D graphics list in which to copy or move the graphics. You must have allocated the 2D graphics list using MgraAllocList(). In-place processing is supported; DstListGraId can refer to the same 2D graphics list as SrcListGraId.
Specifies the type of copy operation to perform. This parameter should be set to one of the following values:
For specifying the type of copy operation to
perform
|
|||||||||||||||||||||||||||||||||||||||
Value | Description | ||||||||||||||||||||||||||||||||||||||
M_DEFAULT |
Same as M_COPY + M_LABEL_VALUE. |
||||||||||||||||||||||||||||||||||||||
M_COPY + |
Specifies graphics from the source 2D graphics list are copied to the destination 2D graphics list. The graphics are not deleted from the source 2D graphics list. (summarize)Specifies graphics from the source 2D graphics list are copied to the destination 2D graphics list. (more details...) |
||||||||||||||||||||||||||||||||||||||
M_MOVE + |
Specifies graphics from the source 2D graphics list are moved to the destination 2D graphics list. The graphics are deleted from the source 2D graphics list. (summarize)Specifies graphics from the source 2D graphics list are moved to the destination 2D graphics list. (more details...) |
You can add one of the following values to the above-mentioned values to specify whether indices or labels are given to the SrcIndexOrLabelArrayPtr parameter.
For specifying whether to use indices or
labels
|
|||||||||||||||||||||||||||||||||||||||
Combination value | Description | ||||||||||||||||||||||||||||||||||||||
M_INDEX_VALUE |
Specifies index values are given to the SrcIndexOrLabelArrayPtr parameter. |
||||||||||||||||||||||||||||||||||||||
M_LABEL_VALUE |
Specifies labels are given to the SrcIndexOrLabelArrayPtr parameter. This is the default value. (summarize)Specifies labels are given to the SrcIndexOrLabelArrayPtr parameter. (more details...) |
Specifies the location inside the destination 2D graphics list at which to insert the graphics. Note that the indices or labels passed to this parameter must refer to valid graphics. Otherwise, an error is generated.
For specifying the insert location in the destination
2D graphics list
|
|||||||||||||||||||||||||||||||||||||||
Value | Description | ||||||||||||||||||||||||||||||||||||||
M_DEFAULT |
Same as M_END_OF_LIST. |
||||||||||||||||||||||||||||||||||||||
Specifies that the graphics will be inserted before the graphic with the specified index in the destination 2D graphics list. (summarize)Specifies that the graphics will be inserted before the graphic with the specified index in the destination 2D graphics list. (more details...) |
|||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
Specifies the index. The index is from 0 (inclusive) to the total number of graphics in the list minus 1. If the given index value is not in that range, an error is generated. You can get the number graphics in the list using MgraInquireList() with M_NUMBER_OF_GRAPHICS. You can get the index corresponding to the label of a graphic using MgraInquireList() with M_INDEX_VALUE. |
|||||||||||||||||||||||||||||||||||||||
Specifies that the graphics will be inserted before the graphic with the specified label in the destination 2D graphics list. (summarize)Specifies that the graphics will be inserted before the graphic with the specified label in the destination 2D graphics list. (more details...) |
|||||||||||||||||||||||||||||||||||||||
Parameters | |||||||||||||||||||||||||||||||||||||||
Specifies the label. The label must be greater than 0. If the label does not exist in the destination 2D graphics list, an error is generated. You can get the label of the last graphic added to the list using MgraInquireList() with M_LAST_LABEL. You can get the label corresponding to the index of a graphic using MgraInquireList() with M_LABEL_VALUE. |
|||||||||||||||||||||||||||||||||||||||
M_END_OF_LIST |
Specifies that the graphics are appended to the end of the destination 2D graphics list. |
Specifies the number of graphics to copy or move.
When using a standard vector (std::vector) overload function in C++, you can pass M_DEFAULT to this parameter and MIL will automatically determine the size based on the number of items in the vector passed to the SrcIndexOrLabelArrayPtr parameter.
Specifies the address of the array containing the indices or labels of the graphics to copy from the source 2D graphics list. If the M_INDEX_VALUE combination constant is used with the Operation parameter, MIL expects the array to contain graphics indices. Otherwise, MIL expects it to contain graphics labels.
The array must contain at least NumGraphics indices or labels. If NumGraphics is set to M_ALL, you must set this parameter to M_NULL.
Note that the indices or labels passed to this parameter must refer to valid graphics. Otherwise, an error is generated.
Specifies the address of the array in which to write the labels that have been automatically given to the copied or moved graphics in the destination 2D graphics list. The labels are written in the same order as the graphics are specified in the SrcIndexOrLabelArrayPtr parameter. If NumGraphics is set to M_ALL, the labels are written in index order.
The array must be at least as large as the number of graphics being moved or copied (NumGraphics). If NumGraphics is set to M_ALL, determine the required size of the array using MgraInquireList() with M_NUMBER_OF_GRAPHICS.
If you do not need the labels of the copied or moved graphics, this parameter can be set to M_NULL.
Header | Include mil.h. |
Library | Use mil.lib. |
DLL | Requires mil.dll. |