Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

If those black grains are visible in the image then it can be done quite easily. Opencv can not xray the rice heap, if the black grains are not visible on the image. Also, x,y coordinate can be know from simple 2D image. For Z coordinate you will need depth estimation, read about disparity map.

If those black grains are visible in the image then it can be done quite easily. Opencv can not xray the rice heap, if the black grains are not visible on the image. image then it will not detect those impurities. Also, your example had high contrast black against white, hopefully your real life requirement will also be like this. Also, x,y coordinate can be know from simple 2D image. For Z coordinate you will need depth estimation, read about disparity map.