Description

The sampled line intensity profiles from the ancestor McLines or McRegions features.

Property type

A Variant value.  

Syntax

object.ProfileValues([Selector], [Channel])

The ProfileValues Property syntax has these parts:

PartDescription
objectAn expression evaluating to an object of type McLineProfiles.
SelectorOptional. A Variant value.

An empty variant, a single negative value, a single index value, or an array of zero or more index values (negative index values are legal but will be ignored).

If the Selector argument is a non-negative scalar value, then the intensity profile array of the ancestor feature from the profiles is exposed a 1 or 2 dimensional array of double values, as described in Remarks.

If the Selector argument is Empty, Error or Null, or any negative value, then the ProfileValues property is exposed as an array of Variant, one for each ancestor feature. The number of elements in the array will be equal to the CountOfProfiles property. Each Variant will hold one profile array, as described in Remarks.

If Selector is an array, then zero or positive values are treated as indices into the ancestor features collection, negative values are legal but ignored. In this case, the the ProfileValues property is exposed as an array of Variant, one for each Selector index value. Each Variant will hold one profile array, as described in Remarks. Index values greater or equal to the CountOfProfiles property are illegal.

ChannelOptional. A Long value.

If non-negative, the color channel to expose profiles for (from 0 up through NumberOfChannels-1). In this case, each ancestor feature's profile array will be a 1-dimensional array, even if NumberOfChannels is greater than 1 (see Remarks). If mcwcAllChannels (-1, the default), all NumberOfChannels channels are returned for each profile sample. In this case each profile will be a 2-dimensional array if NumberOfChannels is greater than 1.

Remarks

When this property is accessed it is automatically computed from the current ancestor features and ancestor image data. This recomputation will be required only if the IsStale property is True; after accessing ProfileValues, IsStale will be False.

One line profile is computed for for each of the ancestor McLines or McRegions features. For ancestor McRegions, the profile follows the closed boundary polygon. Each profile consists of NumberOfSamples luminance samples, with each sample consisting of NumberOfChannels luminance values. Each channel's luminance value may be an average of interpolated sub-sample values both along and perpendicular to the line, depending on the SampleMode, SampleNumbersOrLengths and VirtualWidth properties. The luminance values will be intensity calibrated if the CalibratedIntensity property is True and if the ancestor McImage.IntensityCalibration property has been set.

Each profile from one ancestor McFeatures feature is exposed as a 1D (if NumberOfChannels equals 1 or the Channel argument is non-negative) or 2D array (if NumberOfChannels greater than 1 and the Channel argument is its default of mcwcAllChannels, -1). The length of this array for each channel is the number of samples and will be given by the corresponding element in the NumberOfSamples property.

Formally, if NumberOfChannels is 1 or the Channel argument is non-negative, then for feature index nFeature the profile array is dimensioned as a Double array of length NumberOfSamples(nFeature) (i.e., “Dim OneProfile(0 to NumberOfSamples(nFeature)-1) As Double” in VB, or “double OneProfile[NumberOfSamples(nFeature)];” in C/C++).

If NumberOfChannels is greater then one and the Channel argument is mcwcAllChannels (-1), then for feature index nFeature the profile array is dimensioned as a 2D Double array of length NumberOfChannels with NumberOfSamples(nFeature) sample values per channel, (i.e., “Dim OneProfile(0 to NumberOfSamples(nFeature)-1, 0 to NumberOfChannels-1) As Double” in VB, or “double OneProfile[NumberOfChannels,NumberOfSamples(nFeature)];” in C/C++). These results are organized in the same way as the McHistogram.RawValues and McHistogram.Values results are when more than one channel's histogram is requested; that is, the channel dimension is the slowest moving one.

By default the ProfileValues property exposes the profile from each ancestor feature as an array of Variant, each Variant holding one profile array, as described above. However, if the Selector argument is supplied as a single scalar index value, then only that one profile array is exposed. If the Selector argument is an array of indices, then those feature's profiles are exposed as an array of Variant, each holding one profile array.