Grazing inspection light revealing a fine scratch on a silver disk.

What you need

Use fixed exposure and gain, sample parts and several feasible light positions. Disable automatic camera adjustments during comparison.

Example object/background contrast. 180 vs 60: 0.5 ratio; 120 vs 100: 0.091 ratio.
Example object/background contrast. Original Academy diagram using illustrative values; not a measured hardware result.
Read the diagram as a data table
Values used in the illustration
Condition or componentratio
180 vs 600.5
120 vs 1000.091

The calculation

C = |I_object − I_background| / (I_object + I_background)

C is Michelson-style contrast for two representative intensity levels; both intensities must be measured on the same linear or consistently processed scale.

Worked example

Illustrative numbers. Replace them with your measured inputs.

Object/background values of 180 and 60 give C = 0.50. Values of 120 and 100 give C = 0.091. The first setup separates the two regions more clearly, but reflections and local shadows still need inspection.

Try it step by step

  1. Define the exact feature to detect and select consistent small image regions on it and the nearby background.
  2. Capture several light positions with exposure and gain fixed, recording saturation and shadow behavior as well as mean intensity.
  3. Compare contrast across multiple parts and orientations, particularly reflective or dark variants.
  4. Choose a repeatable mounting arrangement and retest after realistic ambient-light changes.

How to check the result

The preferred arrangement should maintain useful separation across the test set, not merely give the highest contrast on one attractive image.

Common mistake to avoid

High contrast from a specular highlight can disappear with a tiny pose change. This metric alone does not characterize texture, noise or edge sharpness.

Reference reading

Primary references for the underlying models, APIs or application context. The worked numbers and plots above are educational calculations, not results reported by these sources.

Read our methods, limitations and safety notes.