MIL_ID ContextGraId, | //in |
MIL_ID ModelOrResultPatId, | //in |
MIL_ID DstImageBufOrListGraId, | //in |
MIL_INT64 Operation, | //in |
MIL_INT Index, | //in |
MIL_INT64 ControlFlag | //in |
This function draws specific model or result occurrence features in the destination image buffer or graphics list. MpatDraw() can be used with multiple results.
Specifies the identifier of the graphics context to use. This parameter must be set to one of the following values:
For specifying the graphics
context
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
||||||||||||||||||||||||||||||||||||||
M_DEFAULT |
Specifies that the default graphics context of the current MIL application is used. (more details...) |
||||||||||||||||||||||||||||||||||||||
MIL graphics context identifier |
Specifies a valid graphics context identifier, which you have allocated using MgraAlloc(). |
Specifies the model or result buffer identifier from which to extract the features to draw.
Specifies the identifier of the destination image buffer or graphics list into which to draw. The buffer can be any valid MIL image buffer allocated using MbufAlloc...(). The graphics list must be previously allocated using MgraAllocList(). By drawing into a display's overlay buffer or associating the graphics list with the display, you can also annotate an image non-destructively.
If specifying an image buffer, it must not have a region of interest (ROI) associated with it. Using an image buffer with an ROI will cause an error.
Specifies the type of operation to perform. Operations can be added together to draw multiple features at a time. For example, to draw both the result occurrence's bounding box and position, you would specify M_DRAW_BOX + M_DRAW_POSITION as the Operation parameter. The Operation parameter can be set to one or a combination of the values below.
The following operations can extract the features to draw from both a model and a result buffer.
For specifying an operation that can
extract features from both a model and a result buffer
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
||||||||||||||||||||||||||||||||||||||
M_DRAW_BOX + |
Draws the bounding box of the model or of the result occurrence(s). (more details...) |
||||||||||||||||||||||||||||||||||||||
M_DRAW_POSITION + |
Draws a cross at the model's reference position, or at the result occurrence(s) position and angle found in the target image (with respect to the reference position). |
You can use one or more of the following values in combination with each other or with the above-mentioned values, to specify an operation that can extract features to draw only from a model.
The following operations can extract the features to draw only from a model and cannot draw in a graphics list.
For specifying an operation that can
extract features to draw only from a model
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
||||||||||||||||||||||||||||||||||||||
M_DRAW_DONT_CARE |
Draws the model's don't care pixels. |
||||||||||||||||||||||||||||||||||||||
M_DRAW_IMAGE |
Draws the region of the model source image from which the model was extracted. (more details...) |
Specifies the index of the result occurrence to draw. M_DEFAULT always refers to all results. Note, when drawing features of a model, the index must be set to M_DEFAULT.
Specifies where to draw a model. This parameter must be set to one of the values below.
For specifying where to draw the
model
|
|||||||||||||||||||||||||||||||||||||||
Value | Description
|
||||||||||||||||||||||||||||||||||||||
M_DEFAULT |
Specifies to draw the model at the center of the top-left pixel of the destination image; or, if drawing in a graphics list, from the center of the top-left pixel of the image used at the time of annotation. |
||||||||||||||||||||||||||||||||||||||
M_ORIGINAL |
Specifies to draw the model at the offsets used to define the model region in the source image. |
Header | Include mil.h. |
Library | Use mil.lib; milpat.lib. |
DLL | Requires mil.dll; milpat.dll. |