Hello! Someone knows how to change the color of every pixel equal into another color? For example, change all the BGR pixels (130, 0, 0) to (0, 0, 0). Below my code, nevertheless it is not returning what I expected.
for (int i = 0; i < dest.rows; i++) {
for (int j = 0; j < dest.cols; j++) {
if (dest.at<uchar>(i, j) == (130, 0, 0));
dest.at<uchar>(i, j) = (0, 0, 0);
}
}
imshow("result", dest);
waitKey(0);