Opencv how to make edges more visible

I’ve played some more.

useful step: white balance. so the background is absolutely white/gray, which makes thresholding on saturation work better with the clear gummies.

it should also be lit uniformly. the above step has limits.

saturation is much closer to black for the background now:

dilation and threshold: