LearnColorPattern Method
Syntax
CWIMAQVision.LearnColorPattern Pattern, LearnColorPatternOptions
Return Type
On success, this method returns 0. On failure, this method returns a negative number.
Purpose
Creates a description of the color template image for which you are going to look during the color pattern matching stage. This description data is appended to the input color template image. During the color pattern matching step, the color template descriptor is extracted from the color template image and used to search for the template in the color match image.
Remarks
Use this method with RGB32 and HSL32 images.
Parameters
Pattern As CWIMAQImage
The color template image that you want to search for in the image.
LearnColorPatternOptions As CWIMAQLearnColorPatternOptions
A CWIMAQLearnColorPatternOptions object that specifies the parameters the method uses for learning.
Example
Color Pattern Matching Example