Hello, I recently started with opencv and i need a color-replacement logic for image processing. My Images are RGB with transparent background. (I think this is the main reason i struggle)
What i want to do:
- Search for groups that only exist of 0xFFF (White)
- Replace them with 0x000 (Black), but only if the shape has a transparent pixel as a neighbour.
I tried working with connectedComponentsWithStats but the problem is it does not work with rgb + transparent images.
Does anyone have an idea and a hint for me how I could start?
Which methods/algorithms do you recommend for me?
I'm thankful for any kind of help!
Cheers Stefan