Class that represents a 3DPatMax pattern. You can use the methods of
this class to train a new pattern and to search for instances of the
trained pattern in 3D runtime data. You can also search for pattern
instances using the tool class:
Cog3DPatMaxTool.
Inheritance Hierarchy
System MarshalByRefObject
Cognex.VisionPro.Implementation CogObjectBase
Cognex.VisionPro.Implementation CogSerializableObjectBase
Cognex.VisionPro.Implementation CogSerializableChangedEventBase
Cognex.VisionPro3D Cog3DPatMaxPattern
Namespace: Cognex.VisionPro3D
Assembly: Cognex.VisionPro3D (in Cognex.VisionPro3D.dll) Version: 87.1.0.0
Syntax
The Cog3DPatMaxPattern type exposes the following members.
Constructors
| Name | Description | |
|---|---|---|
| Cog3DPatMaxPattern |
Constructs a default Cog3DPatMaxPattern object. You must train this
object before you can use it to search for pattern instances.
| |
| Cog3DPatMaxPattern(Cog3DPatMaxPattern) |
Constructs a deep copy of the supplied Cog3DPatMaxPattern object.
| |
| Cog3DPatMaxPattern(SerializationInfo, StreamingContext) |
Serialization constructor for Cog3DPatMaxPattern object.
|
Methods
| Name | Description | |
|---|---|---|
| CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from MarshalByRefObject.) | |
| Dispose |
Releases all resources used by this Cog3DPatMaxPattern object.
| |
| Dispose(Boolean) | ||
| Equals | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) | |
| Execute |
Searchs the given inputVisionData for instances of
this pattern. The search is performed using the supplied
runParams within the given region.
| |
| Finalize |
Releases all unmanaged resources used by this
Cog3DPatMaxPattern object.
(Overrides Object Finalize .) | |
| GetAttributes |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetClassName |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetComponentName |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetConverter |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetDefaultEvent |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetDefaultProperty |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetEditor |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetEvents |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetEvents( Attribute ) |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
| GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from MarshalByRefObject.) | |
| GetObjectData |
Populates the provided SerializationInfo with the data needed to
serialize the object.
(Overrides CogSerializableObjectBase GetObjectData(SerializationInfo, StreamingContext).) | |
| GetProperties |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetProperties( Attribute ) |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetPropertyOwner |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetTrainedBoundingBox |
Gets the bounding box of the trained points for this pattern.
| |
| GetTrainedVisionData |
Gets a vision data representation of the trained points for this pattern.
| |
| GetType | Gets the Type of the current instance. (Inherited from Object.) | |
| InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from MarshalByRefObject.) | |
| MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
| MemberwiseClone(Boolean) | Creates a shallow copy of the current MarshalByRefObject object. (Inherited from MarshalByRefObject.) | |
| OnChanged(Int64) |
This method should be called internally whenever the object's state may
have changed.
(Inherited from CogSerializableChangedEventBase.) | |
| OnChanged(CogChangedEventArgs) |
This method may be called internally whenever a derived object's state
may have changed and the derived object expresses this change via a
derived CogChangedEventArgs class.
(Inherited from CogSerializableChangedEventBase.) | |
| OnDeserialization |
Perform final deserialization setup.
| |
| ResumeAndRaiseChangedEvent |
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 CogSerializableChangedEventBase.) | |
| SuspendChangedEvent |
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 CogSerializableChangedEventBase.) | |
| ToString | Returns a String that represents the current Object. (Inherited from Object.) | |
| Train |
Trains this 3DPatMax pattern. If the pattern is already trained then
it is untrained and retrained.
| |
| Untrain |
Untrains this 3DPatMax pattern.
|
Fields
| Name | Description | |
|---|---|---|
| SfGetTrainedBoundingBox |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
GetTrainedBoundingBox
may have changed.
| |
| SfGetTrainedVisionData |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
GetTrainedVisionData
may have changed.
| |
| SfGranularity |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
Granularity
may have changed.
| |
| SfGranularityAutoSelect |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
GranularityAutoSelect
may have changed.
| |
| SfGranularityFineFraction |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
GranularityFineFraction
may have changed.
| |
| SfNextSf | ||
| SfOrigin |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
Origin
may have changed.
| |
| SfTrained |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
Trained
may have changed.
| |
| SfTrainRegion |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
TrainRegion
may have changed.
| |
| SfTrainTimeout |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
TrainTimeout
may have changed.
| |
| SfTrainTimeoutEnabled |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
TrainTimeoutEnabled
may have changed.
| |
| SfTrainVisionData |
This bit will be set in the EventArgs of a Changed event every time
the value returned by
TrainVisionData
may have changed.
|
Properties
| Name | Description | |
|---|---|---|
| ChangedEventSuspended |
If nonzero, indicates that the raising of the Changed event has been
suspended. This value is incremented when SuspendChangedEvent is called
and decremented when ResumeAndRaiseChangedEvent is called.
(Inherited from CogSerializableChangedEventBase.) | |
| Granularity |
Gets or sets the size of the subsampling cube to use during training
and runtime. This value is the length of one side of the cube. If
GranularityAutoSelect
is "true" this size value is recomputed automatically when
the pattern is trained, overwriting the previous value.
| |
| GranularityAutoSelect |
Gets or sets whether to automatically recompute the size of the
subsampling cube during pattern training. If "true", the size
computed during training overwrites the existing
Granularity.
Otherwise, it remains unchanged.
| |
| GranularityFineFraction |
Gets or sets the fraction for determining the fine subsampling cube size
to use during training and runtime.
This fraction must be greater than zero and less than or equal to one.
The product of this fraction and
Granularity
specifies the length of one side of the fine subsampling cube.
| |
| HasChanged | (Inherited from CogSerializableChangedEventBase.) | |
| Origin |
Gets or sets the origin for the pattern. This 3D rigid transform maps
points from "Pattern Space" to the 3D selected space of the train data.
In other words, it defines the origin of the pattern's coordinate space
relative to the 3D selected space of the train data.
| |
| StateFlags |
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 CogSerializableChangedEventBase.) | |
| Trained |
Gets whether this pattern is currently trained.
| |
| TrainRegion |
Gets or sets the train region. Only the portion of the 3D train data
that lies within this region is trained by 3DPatMax. If the
supplied region object is null, all of the 3D data is trained.
| |
| TrainTimeout |
Gets or sets the maximum execution time (in msec) allowed when a
3DPatMax pattern is trained. This value only applies if
TrainTimeoutEnabled
is set to "true".
| |
| TrainTimeoutEnabled |
Gets or sets whether to enable the train timeout.
| |
| TrainVisionData |
Gets or sets the 3D data used to train this 3DPatMax
pattern. Only the portions of the 3D data that lie within the
TrainRegion are
trained.
|
Events
| Name | Description | |
|---|---|---|
| Changed |
This event is raised when one or more parts of the object's state may
have changed.
(Inherited from CogSerializableChangedEventBase.) |
Remarks
The pattern object also holds parameters that control the training process. If you change any of these parameters on a trained pattern object, the pattern automatically untrains itself. This ensures that the trained pattern data is in sync with the parameters that created it.
The only properties that do not untrain the pattern when changed are:
Once your pattern is trained you can search for instances of the pattern in a runtime input vision data. You can do this in one of two ways:
- You can call the Execute(ICogVisionData, ICog3DShape, Cog3DPatMaxRunParams) method of this class, or
- You can call the Run method of a Cog3DPatMaxTool class that contains this pattern object.
See Also