Contents
© National Instruments Corporation vii IMAQ Vision for Visual Basic User Manual
Set Search Areas............................................................................................................5-8
Defining Regions Interactively........................................................................5-8
Defining Regions Programmatically...............................................................5-9
Find Measurement Points..............................................................................................5-9
Finding Features Using Edge Detection..........................................................5-9
Finding Lines or Circles....................................................................5-10
Finding Edge Points Along One Search Contour .............................5-11
Finding Edge Points Along Multiple Search Contours.....................5-12
Finding Points Using Pattern Matching..........................................................5-12
Defining and Creating Effective Template Images...........................5-13
Training the Pattern Matching Algorithm.........................................5-15
Defining a Search Area.....................................................................5-16
Setting Matching Parameters and Tolerances...................................5-17
Testing the Search Algorithm on Test Images..................................5-18
Using a Ranking Method to Verify Results......................................5-19
Finding Points Using Color Pattern Matching................................................5-19
Defining and Creating Effective Color Template Images................ 5-20
Training the Color Pattern Matching Algorithm...............................5-21
Defining a Search Area.....................................................................5-22
Setting Matching Parameters and Tolerances...................................5-23
Testing the Search Algorithm on Test Images..................................5-25
Finding Points Using Color Location..............................................................5-25
Convert Pixel Coordinates to Real-World Coordinates.................................................5-26
Make Measurements......................................................................................................5-26
Distance Measurements...................................................................................5-26
Analytic Geometry Measurements..................................................................5-27
Instrument Reader Measurements...................................................................5-28
Identify Parts Under Inspection.....................................................................................5-28
Classifying Samples........................................................................................5-28
Reading Characters..........................................................................................5-29
Reading Barcodes............................................................................................5-29
Read 1D Barcodes.............................................................................5-29
Read Data Matrix Barcode................................................................5-30
Read PDF417 Barcode......................................................................5-31
Display Results..............................................................................................................5-31