Filters
Filter values by
Result buffer type
  • Find orientation result buffer
  • Histogram result buffer
  • Event result buffer
  • Projection result buffer
  • Extreme result buffer
  • Difference counting result buffer
| Customize Help
| Save Settings

MimGetResult1d



Function Map
Synopsis
Get the specified number of result entries from an image processing result buffer.
Syntax
void MimGetResult1d(
MIL_ID ResultImId, //in
MIL_INT OffEntry, //in
MIL_INT NbEntries, //in
MIL_INT64 ResultType, //in
void *UserArrayPtr //out
)
Description

This function retrieves the specified number of result entries from the specified result buffer and stores them in the specified one-dimensional destination user array.

If your target image was associated with a camera calibration context, positional and dimensional results are, by default, returned with respect to the relative coordinate system of the image. Otherwise, these results are returned in pixels, relative to the top-left pixel in the target image.

If your target image was associated with a camera calibration context, but you want to retrieve positional and dimensional results in pixel units, use MimControl() with the M_RESULT_OUTPUT_UNITS control type set to M_PIXEL. However, note that if you set M_RESULT_OUTPUT_UNITS to M_WORLD without specifying a calibrated image in which to calculate the results, MimGetResult1d() will generate an error.

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
ResultImId

Specifies the identifier of the image processing result buffer from which to get results.

OffEntry

Specifies the offset of the first result to read. The given value must be within the number of allocated result entries.

NbEntries

Specifies the number of result entries to get, starting from the entry specified by the OffEntry parameter.

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 parameter.

ResultType

Specifies the type of result(s) to retrieve.

See the Parameter associations section for possible values that can be specified.

UserArrayPtr
Accepts the address of one of the following (see the Parameter associations section for specifics on which is expected):
  • array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ]
  • array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ]
  • array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]
  • array of type MIL_INT32 [optionally, in C++: a reference to a std::vector<MIL_INT32> ]
  • array of type MIL_INT64 [optionally, in C++: a reference to a std::vector<MIL_INT64> ]
  • MIL_DOUBLE
  • MIL_FLOAT
  • MIL_INT
  • MIL_INT32
  • MIL_INT64

Specifies the address of the one-dimensional array in which to write the results read from the MIL result buffer.

See the Parameter associations section for possible values that can be returned.

The table below lists possible values for the ResultType parameter and possible values returned to the UserArrayPtr parameter.

function map For specifying the type of result to retrieve
Click to summarize
ResultType
Description
UserArrayPtr
- Possible values returned
Click to summarize M_ANGLE +

Retrieves the best orientations (angle values) calculated by MimFindOrientation() and stored in an M_FIND_ORIENTATION_LIST result buffer. MIL sorts the resulting angles according to their associated score (M_SCORE); angles with higher scores are listed first.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]  |  array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ] MORE
Click to summarize M_CUMULATIVE_VALUE +

Retrieves the cumulative histogram values from an M_HIST_LIST result buffer.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ] MORE
Click to summarize M_NB_EVENT +

Retrieves the number of events from an M_EVENT_LIST result buffer. Note that if the result buffer did not have the required number of entries to hold the total number of events that satisfied the condition, the number returned is limited to the number of entries in the result buffer.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: address of a MIL_INT
Click to summarize M_PERCENTILE_VALUE +

Retrieves the inverse cumulative histogram from a M_HIST_LIST result buffer. Each value retrieved is the pixel value whereby n % of the pixels have a value less than or equal to that value, where n is the index of the user array.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ] MORE
Click to summarize M_POSITION_X +

Retrieves the image X-coordinate of each event from an M_EVENT_LIST result buffer.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]  |  array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ] MORE
Click to summarize M_POSITION_Y +

Retrieves the image Y-coordinate of each event from an M_EVENT_LIST result buffer.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]  |  array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ] MORE
Click to summarize M_SCORE +

Retrieves the score attributed to each orientation (angle) value calculated by MimFindOrientation() and stored in an M_FIND_ORIENTATION_LIST result buffer. The scores are represented as percentages relative to the other orientations stored in the result buffer. MIL lists higher scores first.

The first orientation in the buffer will always be the most dominant orientation with a score of 100.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]  |  array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ] MORE
Click to summarize M_VALID +

Retrieves the validity of projection data, from an M_PROJ_LIST result buffer. This is only useful when a region of interest is associated with the source image buffer of the projection operation.

A lane of pixels will contain no valid pixels if it is excluded from the region of interest associated with the source image; this means that projection data cannot be calculated for the lane. However, the M_PROJ_LIST result buffer contains an entry for each lane of pixels found in the source image, regardless of the use of a region of interest. So when your source image buffer has a region of interest, you should use M_VALID to check the validity of the data for the lane in the result buffer.

Note that for an M_SUM projection operation, if a lane of pixels does not contain valid projection data, a neutral pixel value of 0 is used for that lane. In this case, M_VALID will indicate valid projection data for all lanes of pixels in the image.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]  |  array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ] MORE
Click to summarize 0

Specifies invalid projection data for the lane due to no valid pixels residing in the lane of pixels in the source image corresponding to the M_PROJ_LIST entry.

Click to summarize Value != 0

Specifies valid projection data for the lane.

Click to summarize M_VALUE +

Retrieves values from an M_HIST_LIST, M_PROJ_LIST, M_EXTREME_LIST, M_EVENT_LIST, or M_COUNT_LIST result buffer.

If an M_EXTREME_LIST type result buffer contains both the minimum and maximum value of an image, the minimum is written first, followed by the maximum.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]  |  array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ] MORE
Combination value for M_CUMULATIVE_VALUE; M_VALUE.

You can add the following value to the above-mentioned values to get the requested results as a percentage.

function map For retrieving results as a percentage
Click to summarize
ResultType
Description
UserArrayPtr
- Possible values returned
Click to summarize M_PERCENTAGE

Retrieves the histogram values or cumulative histogram values, as a percentage. The values are multiplied by 100 and then divided by the total number of elements in the histogram.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ] MORE
Combination values for the values listed in For specifying the type of result to retrieve.

You can add one of the following values to the above-mentioned values to cast the requested results to the required data type.

Note: In C++, when using a standard vector (std::vector) instead of an array, the values listed in this combination table must not be used. If you need to use a specific data type, instantiate the vector with the necessary data type.

function map For the ResultType parameter to cast the required results to the requested data type
Click to summarizeResultType Description
UserArrayPtr
- Possible values returned
Click to summarize M_TYPE_MIL_DOUBLE

Casts the requested results to a MIL_DOUBLE.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_DOUBLE [optionally, in C++: a reference to a std::vector<MIL_DOUBLE> ]  |  address of a MIL_DOUBLE MORE
Click to summarize M_TYPE_MIL_FLOAT

Casts the requested results to a MIL_FLOAT.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_FLOAT [optionally, in C++: a reference to a std::vector<MIL_FLOAT> ]  |  address of a MIL_FLOAT MORE
Click to summarize M_TYPE_MIL_INT

Casts the requested results to a MIL_INT.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT [optionally, in C++: a reference to a std::vector<MIL_INT> ]  |  address of a MIL_INT MORE
Click to summarize M_TYPE_MIL_INT32

Casts the requested results to a MIL_INT32.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT32 [optionally, in C++: a reference to a std::vector<MIL_INT32> ]  |  address of a MIL_INT32 MORE
Click to summarize M_TYPE_MIL_INT64

Casts the requested results to a MIL_INT64.

(summarize)
Expand data type infoCollapse data type info UserArrayPtr extra info
Data type info: Data type: array of type MIL_INT64 [optionally, in C++: a reference to a std::vector<MIL_INT64> ]  |  address of a MIL_INT64 MORE
Remark
  • [MIL-Lite]
    Note that some of the values listed above are not available in MIL-Lite. See the result's corresponding operation function for MIL-Lite availability.
Compilation information
Header Include mil.h.
Library Use mil.lib; milim.lib.
DLL Requires mil.dll; milim.dll.
ANGLE CUMULATIVE VALUE NB EVENT PERCENTILE VALUE POSITION X POSITION Y SCORE VALID VALUE PERCENTAGE TYPE MIL DOUBLE TYPE MIL FLOAT TYPE MIL INT TYPE MIL INT32 TYPE MIL INT64 TYPE MIL FLOAT TYPE MIL FLOAT TYPE MIL FLOAT TYPE MIL FLOAT TYPE MIL FLOAT TYPE MIL FLOAT TYPE MIL FLOAT TYPE MIL FLOAT