I want some ideas to get the level of a water/liquor in a cup. i tried many ideas (contours, edges,...) but nothings is working. So any ideas that i can explore.
1 Answer
Constrain the environment. Best is to make sure the glass is always the same (position and shape), take a picture of the glass empty and use that as reference. Otherwise, you'll need some algorithm to first detect the position of the glass (if the background is constrained, you can use that).
If the liquid is isolated, I'd recommend applying a sobelY filter and something to reduce noise. Take a vertical line out of the graph and identify each step (top glass, water level, bottom glass).