Contrast
The Contrast tool allows you to determine whether a feature is present or not present based on the contrast value of the pixels, or the difference between the mean greyscale value of the bright pixels and the mean greyscale value of the dark pixels, in the defined region.
The Contrast tool is useful in situations where the feature on a good part has very distinct light or dark areas as compared to a bad part. For example, verifying the presence of dark print on a white label.
-
Open the Inspect tool palette, expand the Presence/Absence tool group, and select the Contrast tool.
- In the dialog that appears, define the region by resizing and repositioning the box on the acquisition display screen. You can change the shape of the box using the Search Shape dropdown on the right. The available shapes are Rectangle, Circle, Annulus, and Polygon.
-
You can also add a subregion to your model region to mask out irrelevant or confusing features by right clicking on the acquisition display screen, and selecting Add Subregion > Shape in the dropdown menu that appears. By default, the subregion is added to the model region, but you can change it to subtract by right clicking on the acquisition screen, and selecting Subregion Operation > Subtract in the dropdown menu.
- Click OK.
Toggle the Normal/Inverted toggle to change the way the tool result is generated. If set to Normal, the tool produces a passing result if the contrast value falls between the defined minimum and maximum values. If set to Inverted, the tool produces a passing result if the contrast value falls outside the defined minimum and maximum values.
Adjust the valid range by changing the Minimum and Maximum contrast values using the sliders or by providing the numerical values in the boxes below the slider.
Click Set Min/Max to use automatically calculated minimum and maximum contrast values. The automatically calculated minimum and maximum values are 10% below and above the current contrast value within the defined region when you add the tool or click the Set Min/Max button.
You can also enable advanced tool settings if your job requires more complex configuration. For more information on the advanced tool settings that are available, see Advanced Tool Settings.