| MIL 10 Reference
| Customize Help
| Save Settings

MpatSetCenter



See also
Availability
Not available in MIL-Lite
Available in MIL

Available on Windows
Available on Linux

Available on Non-Matrox computer
Available on Matrox 4Sight-X
Available on Matrox 4Sight GP
Available on Matrox Supersight
function map Function map
Examples
None.
Synopsis
Set the reference position of a model.
Syntax
void MpatSetCenter(
MIL_ID ModelId, //in
MIL_DOUBLE OffX, //in
MIL_DOUBLE OffY //in
)
Description

This function sets the reference position of the specified model. The default reference position is equal to ((SizeX - 1) / 2.0, (SizeY - 1) / 2.0) (relative to the model origin). All positional search results are based on this defined model's reference position, relative to the top-left corner of the image in which the search is performed.

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 if there is complementary information.
Parameters
This function is not supported on the selected boards.
Parameters
ModelId

Specifies the identifier of the model for which to change the reference position.

OffX INQ

Specifies the X-offset of the new model's reference position relative to the model origin. Note that the reference position need not be in the model.

The default value is half of the model's width.

OffY INQ

Specifies the Y-offset of the new model's reference position relative to the model origin. Note that the reference position need not be in the model.

The default value is half of the model's height.

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