Printed packaging can hide a liquid boundary even when the container looks partly transparent. Near-infrared illumination may improve the view, but changing wavelength alone does not establish a reliable inspection. You need enough light through the complete package, a measurable difference between empty and filled regions, and an exposure compatible with production motion. This guide gives you a sample-based test plan for deciding whether NIR backlighting can detect the required fill height before you commit to hardware.
Decide from empty and filled images, not appearance
Use NIR lighting for fill level inspection only when testing demonstrates three things: the package transmits enough light, the contents create a distinguishable boundary, and printing does not imitate that boundary. A package that looks opaque to your eyes can transmit NIR; another with similar visible appearance may block it.
Start with backlighting: place the source behind the package and the camera opposite it. This measures transmitted light rather than relying mainly on surface appearance. The broader liquid-level lighting guide explains the alternative geometries when transmission is unsuitable.
Your first decision is therefore not which camera has the most pixels. It is whether the optical signal survives the real packaging stack. Test empty and filled packages of the same construction, including labels, seams and closures where they intersect the measurement region.
Define the smallest unacceptable height error before testing. A clearly visible liquid boundary is useful only if its detected position supports that requirement.
Separate wall transmission, print suppression and liquid contrast
These are different properties, and improving one does not guarantee the others.
Wall transmission determines how much illumination reaches the camera through the package. A filled-container view may include two walls, adhesive, a printed layer and the liquid path. Testing a single loose film can therefore give a misleadingly optimistic result.
Print suppression means the printed pattern becomes less prominent relative to the inspection feature. Some pigments become less obstructive in NIR; others remain strongly absorbing. Metallic layers and opaque structures may prevent useful transmission altogether.
Liquid contrast is the difference between empty and filled optical paths. Absorption, scattering and refraction can contribute. Depending on geometry and materials, the filled region need not always appear darker.
For a fixed camera setting, estimate relative transmission using dark-corrected image values:
The open reference is an image without the package. Avoid saturation and keep exposure, gain, aperture and source setting unchanged between each reference and its package images. The contrast expression is undefined when both corrected signals are zero and becomes unreliable near the noise floor.
These are camera-based comparison metrics, not calibrated material spectroscopy. The spectral-band comparison explains why moving between visible, NIR and other bands changes the material interactions you observe.
Build a sample matrix that can disprove the idea
A useful screening exercise includes more than one attractive sample. As an initial engineering trial, collect at least three packaging lots and test several rotations from each. That is a starting matrix, not a statistical qualification plan.
Include:
- Empty packages, to reveal printing and seams without liquid interference.
- Packages filled below, at and above the decision boundary.
- The darkest and lightest print variants expected in production.
- Seams facing the camera, facing the light and outside the measurement region.
- Representative contents, including expected changes in appearance and formulation.
- Samples with bubbles or foam if those conditions occur during inspection.
Compare visible illumination with available NIR wavelengths. Common screening choices include 850 nm and 940 nm, but wavelength availability does not establish which will work on your package.
| Test condition | Question it answers | Evidence to retain |
|---|---|---|
| Open optical path | Is the reference image usable? | Unsaturated brightness and spatial uniformity |
| Empty package | Do walls and print transmit enough light? | Transmission map and seam positions |
| Filled package | Does liquid create a stable difference? | Boundary position and empty-to-filled contrast |
| Rotated package | Can artwork imitate the boundary? | False edges at each orientation |
| Moving package | Does the signal survive production exposure? | Blur, detection result and timing |
Keep fixed settings within each wavelength comparison. Across wavelengths, assess both a common exposure and the exposure each setup needs for a usable image. Equal controller settings do not imply equal optical output or equal camera response.
Use the lens and lighting test plan to organize image naming, settings records and acceptance criteria.
Set the view and sampling before judging the boundary
Keep the camera approximately perpendicular to the package face used for measurement. Define a narrow measurement strip away from seams where possible. Inspect several adjacent image columns rather than trusting one column that artwork or a bubble can obscure.
A two-dimensional image does not automatically report the physical height at the container center. Curved walls, package tilt and a meniscus can move or reshape the apparent boundary. Calibrate the detected feature against known fill heights in the actual fixture.
For an illustrative sampling calculation, suppose the vertical field of view is 120 mm. You want a 0.8 mm height change represented by eight pixels:
This is a sampling target, not a claim of measurement accuracy. Lens performance, calibration, boundary ambiguity and mechanical variation still contribute error. Use the dimensional-inspection resolution guide to distinguish pixel sampling from demonstrated measurement capability.
Focus with the intended wavelength and the final optical arrangement. Do not assume a lens focused under visible illumination remains correctly focused after changing to NIR.
Check the exposure budget before selecting a light
A convincing stationary image may require an exposure that is unusable on a moving conveyor. Calculate the motion limit early, using object-space sampling and the motion component across the measured image.
For example, suppose the package moves at 500 mm/s, sampling is 0.10 mm/pixel, and the allowed blur is 0.25 pixel:
If the stationary trial required 0.40 ms, reaching 0.05 ms means reducing exposure by a factor of eight. Approximately eight times the detected irradiance would maintain the same signal in the linear regime, with other settings unchanged. That is an optical requirement, not permission to exceed a light's electrical limits.
Opening the aperture can increase signal but changes depth of field. Increasing gain does not replace missing photons and can make weak contrast harder to interpret. Read the moving-part exposure guide before using longer exposure as the primary remedy.
A short flash can help only when the light, driver, camera and timing support the intended operating mode. Rolling-shutter acquisition also needs a compatible illumination strategy; a brief pulse may not expose all rows uniformly.
Work through a complete contrast example
Consider a hypothetical trial using fixed exposure, gain and aperture. All values below are dark-corrected digital image values from representative patches. They are examples, not performance claims for any listed product.
| Measurement | Open path | Empty package | Filled package |
|---|---|---|---|
| Mean image value | 200 | 150 | 60 |
| Temporal standard deviation | Not used here | 5 | 6 |
The estimated empty-path transmission is:
The contrast is promising, but it does not show whether repeated acquisitions remain separable. A simple temporal separation score is:
Calculate temporal variation from repeated images of the same region under the same condition. Spatial variation caused by printing is a separate challenge and should not be silently mixed into that noise estimate.
There is no universal passing score for this application. A high value in selected patches does not rule out a printed stripe that generates a stronger false boundary elsewhere.
Next, plot intensity against vertical position through several adjacent strips. Check whether the liquid transition appears at the expected height in each strip. Then apply the same detection method to empty packages: it should not report a plausible fill boundary from artwork alone.
Finally, repeat at the motion-limited exposure. Record detected height against a known reference across package rotations and fill levels. Choose an acceptable maximum height error and permitted false-decision rate before evaluating the results, rather than adjusting them to fit the images.
Choose candidate hardware without assuming spectral compatibility
Start with backlights large enough to cover the measurement region and expected package movement. The lighting finder helps narrow the geometry and operating mode once testing establishes the optical requirement.
The LS-BKL-0416 is listed as an 850 nm Infrared backlight with a 136.4 x 136.4 mm lit area and constant-on operation only. Do not plan to pulse it unless an approved configuration is separately documented.
The LS-BKL-1468 is a red backlight candidate for a visible reference trial. These candidates are not a matched radiometric pair; compare the resulting image signal and usable exposure rather than assuming equivalent output.
- Size
- 100-200 mm
- Type
- Standard
- Size
- 100-200 mm
- Type
- Standard
For area scan cameras, verify spectral response, any infrared-blocking filter, exposure control and triggering behavior. Monochrome acquisition can simplify intensity analysis, but the monochrome label alone does not establish adequate NIR response.
The LS-CMR-0166 is a USB3 rolling-shutter camera candidate. Its listing does not establish the spectral sensitivity required for this inspection, so confirm that separately before selection.
- Sensor format
- 1/1.7"
- Interface
- USB3
- Resolution
- 12 MP
- Shutter
- Rolling
Use the camera finder after defining sampling and motion requirements. Confirm lens transmission and filter passband as well: a camera and light cannot compensate for an optical component that blocks the intended band.
Silhouettes, edges and gauging
1,592 models · from $86.00Recognize when NIR is the wrong answer
NIR does not inherently remove glare. Surface reflections remain possible, and curved walls can redirect backlight into bright bands or dark caustics. Changing wavelength may change their appearance without eliminating their cause.
If glare is the dominant problem, investigate source geometry and viewing angle. The bottle glare and recognition guide addresses that distinction. The LED-colour contrast guide also explains why wavelength selection should follow the feature being detected.
Reject the approach when the package transmits too little light at an acceptable exposure, or when liquid and empty paths remain indistinguishable. The same applies when seams repeatedly mask the boundary or foam prevents a stable relationship between the visible interface and the required fill height.
A different viewing region, package presentation or sensing method may then be more appropriate. Avoid treating stronger illumination or a more complicated algorithm as proof that the underlying optical signal is sufficient.
Finish with a repeatable acceptance checklist
Before ordering the final station, document the following:
- Packaging coverage: test production artwork, materials, seams and expected rotations, not only unprinted samples.
- Reference images: retain open-path, dark, empty and filled images with their acquisition settings.
- Boundary definition: specify whether the measurement follows the meniscus, bulk liquid or another validated feature.
- Sampling: show the field-of-view arithmetic and verify calibration against known height changes.
- Exposure: demonstrate detection at the required motion speed without unacceptable blur or row-dependent illumination.
- Variation: repeat across relevant lots and contents, including expected foam and bubbles.
- Decision performance: measure height error, false acceptance and false rejection using samples outside algorithm tuning.
- Hardware compatibility: confirm spectral response, lens transmission, control mode and permitted electrical operation.
Keep representative failure images alongside passing images. They explain the inspection limits more clearly than a single well-lit demonstration and help detect changes after packaging revisions.
Once those checks pass, use the lighting configurator to assemble the candidate setup. If transmission or exposure remains uncertain, send your sample matrix and measured results through applications support before finalizing the selection.
Questions
Can NIR detect liquid levels through printed packaging?
Only when the package and its printed layers transmit enough of the chosen wavelength. Some artwork becomes less prominent, while other inks, seams or barrier layers still obscure the liquid. Compare actual empty and filled packages across production variants before selecting a wavelength.
Should I test 850 nm or 940 nm first?
Neither wavelength is universally better. The useful result depends on the combined transmission of the walls, printing and contents, plus camera sensitivity and available illumination. Compare boundary detection at the required exposure rather than selecting the wavelength that produces the brightest stationary image.
Can an existing visible-light camera be used for NIR?
Possibly, but verify its spectral response and whether its optical path includes an infrared-blocking filter. Also check lens transmission, focus and acquisition timing. A successful visible-light image or a monochrome sensor designation does not establish suitability for the intended NIR inspection.
Does NIR illumination remove reflections from packaging?
NIR changes material response, but reflections still follow the illumination and viewing geometry. Curved packaging can concentrate or redirect transmitted light. If reflections dominate the measurement region, adjust geometry and validate the resulting boundary instead of expecting a wavelength change alone to solve them.
What should I provide when requesting a sample evaluation?
Provide representative empty packages, controlled fill heights, artwork variants, seams and expected contents. Include conveyor speed, allowed height error, available viewing space and images with recorded settings. These details establish whether the limiting factor is transmission, contrast, sampling or exposure before hardware is selected.


