Description

Forces the computation of the Histogram regardless of the internal state of the operator and its source image.

Return Type

None  

Syntax

object.Compute [SourceImage]

The Compute Method syntax has these parts:

PartDescription
objectAn expression evaluating to an object of type McHistogram.
SourceImageOptional. A Variant value.

Source McImage for the computation for global instances of McHistogram (ones with no ancestor McImage). This argument is required for global instances of McHistogram, and it must be missing for McHistogram instances with an image ancestor.

Remarks

Calculated values depend on BinCount, Interpretation, Mode and IMcImage.RangeMin, IMcImage.RangeMax for floating point images. Histogram results are based only on pixels interior to the source image's Aoi unless the Mode property mchmIgnoreAoi bit is set.

You generally will not need to call Compute directly. This method is called automatically whenever one of the Histogram properties is requested and the cached data is not in sync with the parent image and the current option set. It is also possible to pass an image parameter in order to compute the Histogram on an image when there is no ancestor McImage.

Results can be accessed using the McHistogram properties RawValues, Values and BinXValues, as well as the standard statistical properties.

Note

If the source McImage.ActiveFrameRange specifies a Range, then unless the Mode mchmProcessActiveFrameOnly bit is set, then the histogram is computed from all of the specified frames. If the Mode mchmProcessActiveFrameOnly bit is set, then only the McImage.ActiveFrame is conisidered. If the Mode mchmIgnoreAoi bit is set, then any Aoi is ignored.