I repost the question due to unclear previous one. I'm doing a project, in this project I have to enhance image A to be most similar to image B, as shown in the attached image.
The original image only has green and red color pixels.
Image 1:

Image 2:

As you can see, the pixels in the red line and green line are lost or damaged some where. I want to enhance the conner, make the line full filled and straighthen them.
Can anyone help me to solve this?
Thank you
I tried to separate the green and red area, then applied binary, but the outomes were not good enough.
Источник: https://stackoverflow.com/questions/781 ... -in-images