1 | initial version |
you should not do anything per pixel, but process whole rows at a time:
for(int i=0; i<image.size(); i++)
{
Mat wb = (w[i] - b[i]) * 0.9;
for (int j=0; j<images[i].rows; j++)
{
image[i].row(j) = (image[i].row(j) - b[i]) / wb;
}
}
2 | No.2 Revision |
you should not do anything per pixel, but process whole rows at a time:
for(int i=0; i<image.size(); i++)
{
Mat wb = (w[i] - b[i]) * 0.9;
for (int j=0; j<images[i].rows; j++)
{
divide( image[i].row(j) - b[i], wb, image[i].row(j) = (image[i].row(j) - b[i]) / wb;
);
}
}
3 | No.3 Revision |
you should not do anything per pixel, but process whole rows at a time:
for(int i=0; i<image.size(); i++)
{
Mat wb = (w[i] - b[i]) * 0.9;
for (int j=0; j<images[i].rows; j++)
{
divide( image[i].row(j) - b[i], wb, (image[i].row(j) image[i].row(j) );
}
}