I have an object that I want to paste into image but the object has some white pixels that shouldn’t exist on the edges. How can I remove these white pixels? I have tried inpainting but it doesn’t seem to create anything useful. Is there any other method that I can use in OpenCV?
Inpainting has no good results even though the mask is correct and I have tried both Navier-Stokes and TELEA but I saw nothing.
Using morphology didn’t work as well because I need to fill in those pixels accordingly on rgb image and the output wasn’t what I need.