I have some images that they have dead pixels (or pixels that has bad result) I have raw data (bayered data).
How can I detect and fix them using OpenCV?
I tried to fix them using a filter on bayer data. In my algorithm, I detect the color of each pixel and if it was green used an X pattern to find neighboring green pixels and if the value of current pixel is more than say 40 of the neighboring pixels, the pixel value changes by average of neighboring pixels.
did the same things for red and blue using + pattern.
But it did not fix the issue.
Any algorithm which can fix these dead pixels?