Description

Construct a new McImage from a rectangular region of interest.

Return Type

A McImage object.  

The newly created IMcImage.

Syntax

object.Cut (Left, Top, Right, Bottom, [Flags], [vSourceImg])

The Cut Method syntax has these parts:

PartDescription
objectAn expression evaluating to an object of type McGeometry.
LeftRequired. A Long value.

ROI left upper corner x coordinnate

TopRequired. A Long value.

ROI left upper corner y coordinnate

RightRequired. A Long value.

ROI bottom right corner x coordinnate

BottomRequired. A Long value.

ROI bottom right corner y coordinnate

lFlags

Optional image creation flags for the new image. By default the value is zero, which creates a visible image that is part of the Images collection. See mcImageCreateFlags for the list of supported flags.

FlagsOptional. A mcImageCreateFlags enumeration, as described in settings.
vSourceImgOptional. A Variant value.

Optional source image, operator applies to parent image when parameter is omitted.

Settings

The settings for Flags are:

ConstantValueDescription
 mcicfDefault0
 mcicfContiguous1

If set, frames are allocated contiguously, and you cannot add to the FrameCount at a later time.

 mcicfNoInit2

Default is to initialize to 0 (black), this flag suppresses initialization.

 mcicfNoAddToCollection4

If set, the image is created, but not added to the collection (see Notes).

 mcicfNotVisible8

If set, the image is created, possibly added to collection (see above), but not made visible.

 mcipfNoImportProperties8388608

Suppress ImportProperties for functions creating an image from another.

Remarks

The new image has the same type as the source image, and the same number of frames as the currently selected active frame range. The new image never has an Aoi.

Notes

The McImage CopyToNewImage method is a much more flexible routine that can also be used to create a new image from a portion of a source image. In addition to other features, CopyToNewImage allows you to name the new image optionally copy the Aoi and/or mask by it.