ICogModelFeature InterfaceCognex VisionPro 9.21 SR1
A model feature (CogModelFeature) has the model properties Weight and Polarity.

Namespace: Cognex.VisionPro
Assembly: Cognex.VisionPro.Core (in Cognex.VisionPro.Core.dll) Version: 85.1.0.0
Syntax

public interface ICogModelFeature : ICogChangedEvent

The ICogModelFeature type exposes the following members.

Methods

  NameDescription
Public methodGetEffectivePolarity
If this feature has no ParentFeature, then its effective polarity is the value of the Polarity property. If this feature has a ParentFeature, then the effective polarity is the Polarity times the effective polarity of the ParentFeature.
Public methodGetEffectiveWeight
If this feature has no ParentFeature, then its effective weight is the value of the Weight property. If this feature has a ParentFeature, then the effective weight is the Weight times the effective weight of the ParentFeature.
Public methodResumeAndRaiseChangedEvent
Re-enables raising of the Changed event after SuspendChangedEvent has been called, and raises the Changed event if the ChangedEventSuspended count is reduced to zero and any changes were made while events were suspended. Must be called once for each call to SuspendChangedEvent.
(Inherited from ICogChangedEvent.)
Public methodSuspendChangedEvent
Temporarily suspends the raising of the Changed event. May be called more than once, and a corresponding call to ResumeAndRaiseChangedEvent must be made for each call to SuspendChangedEvent.
(Inherited from ICogChangedEvent.)
Top
Properties

  NameDescription
Public propertyChangedEventSuspended
Indicates if the raising of the Changed event has been suspended.
(Inherited from ICogChangedEvent.)
Public propertyParentFeature
If this feature has a ParentFeature, then Weight and Polarity are defined with respect to the parent. The effective weight (or polarity) of this feature is its Weight (or Polarity) times the parent's effective weight (or polarity).
Public propertyPolarity
Returns/sets the polarity of this feature. The polarity of a given feature may be -1, 0(undefined), or +1. Polarities of +1 or -1 define where to find brighter pixels relative to the feature geometry, and 0 means undefined.
Public propertyStateFlags
Returns the complete set of state flags supported on this object. The flags may be indexed by name as shown in the following C# code snippet: if (changedObject.StateFlags["Color"] & eventArgs.StateFlags) { ... }
(Inherited from ICogChangedEvent.)
Public propertyWeight
Returns/sets the weight of this feature. The weight of a feature determines its relative importance compared to other features of the model. The weight defaults to 1.0.
Top
Events

  NameDescription
Public eventChanged
This event is raised when one or more parts of the object's state may have changed.
(Inherited from ICogChangedEvent.)
Top
Remarks

CogModelFeature holds the Weight and Polarity properties of a model feature.

See Also