| MIL 10 Reference
| Customize Help
| Save Settings

MimProject



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

Available on Windows
Available on Linux

Partially supported on:
Partially supported on Matrox GPU processing driver

Fully supported on:
Fully supported on Host system
Fully supported on Matrox CronosPlus
Fully supported on Matrox GigE Vision driver
Fully supported on Matrox IEEE 1394 IIDC driver
Fully supported on Matrox Iris GT
Fully supported on Matrox Morphis
Fully supported on Matrox Morphis QxT
Fully supported on Matrox Orion HD
Fully supported on Matrox Radient eCL
Fully supported on Matrox Radient eV-CXP
Fully supported on Matrox Solios eA/XA
Fully supported on Matrox Solios ecl/xcl/ev-cl
Fully supported on Matrox USB3 Vision driver (requires Update 19)
Fully supported on Matrox Vio

For any information regarding a MIL system added during a MIL Update, see the MIL system’s release note

Available on Non-Matrox computer
Available on Matrox 4Sight-X
Available on Matrox 4Sight GP
Available on Matrox Supersight
function map Function map
Examples
Synopsis
Project a 2D image into 1D.
Syntax
void MimProject(
MIL_ID SrcImageBufId, //in
MIL_ID ProjResultImId, //in
MIL_DOUBLE ProjectionAngle //in
)
Description

This function projects a two-dimensional buffer into a one-dimensional buffer from the specified angle, and writes results to the specified projection result buffer. The results are generated by adding all pixel values along each diagonal in the image at the specified projection angle. The 90° projection of the image is known as the row profile; the 0° projection as the column profile.

Note that, if the sum of any diagonal is larger than the depth of the result buffer, the result will be undefined.

You can limit this function's results to a region of the source image buffer using a region of interest (ROI) set using MbufSetRegion().

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
SrcImageBufId

Specifies the identifier of the data source of the image. This parameter must be given an image buffer identifier. The buffer must be 1-band.

This image buffer can have an ROI set using MbufSetRegion(). The ROI must be defined in raster format (M_RASTER or M_VECTOR_AND_RASTER). An error is generated if the ROI is only in vector format (M_VECTOR).

[Matrox GPU processing driver]

The source image buffer must be unsigned monochrome 8- or 16-bit, M_BGR32 packed, or floating-point.

ProjResultImId

Specifies the identifier of the destination of the projection results. This parameter must be given the identifier of an image processing result buffer allocated with MimAllocResult() and an M_PROJ_LIST type. The buffer should have as many locations as there are lines to project in the image at the specified angle.

You can read the projection values from the result buffer, using MimGetResult1d() or MimGetResult(), specifying M_VALUE as the result type.

[Matrox GPU processing driver]

The result buffer must be floating-point.

ProjectionAngle

Specifies the angle of projection, in degrees. Predefined projection angles are the following:

function map For specifying the angle of projection in degrees
CollapseValue Description
MIL system-specific
tooltip (†)
Collapse M_0_DEGREE

Specifies a 0° projection (column profile).

(summarize)
a b c d e f g h i j k l m n o p q r s
MIL system specific

Source buffer must have a number of lines that is a multiple of 4 if this number is smaller than the number of locations in the result buffer.

d
Collapse M_90_DEGREE

Specifies a 90° projection (row profile).

a b c d e f g h i j k l m n o p q r s
Compilation information
Header Include mil.h.
Library Use mil.lib; milim.lib.
DLL Requires mil.dll; milim.dll.
PROC VECTOR 0 DEGREE 90 DEGREE