Project a 2D image into 1D.


void MimProject(SrcImageBufId, ProjImResultId, ProjAngle)

MIL_ID SrcImageBufId; Source image buffer identifier
MIL_ID ProjImResultId; Projection image processing result buffer identifier
double ProjAngle; Angle of projection


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.

The SrcImageBufId parameter specifies the identifier of the data source of the image. This parameter must be given an image buffer identifier.

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

The ProjAngle parameter specifies the angle of projection, in degrees. Predefined projection angles are the following:

M_0_DEGREE 0° projection (column profile).
M_90_DEGREE 90° projection (row profile).


Only 0° and 90° projection angles are supported.

See also

MimAllocResult, MimGetResult, MimGetResult1d