Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Hello! I am sorry, but did not answer early. Correct code in this case:

float c = (float)(n / 50);
for (int i = 0; i < imgRez.rows; i++) 
for (int j = 0; j < imgRez.cols; j++)
for (int k = 0; k < imgRez.channels(); k++)
pano.at<Vec3b>(i, j)[k] = leftImg.at<Vec3b>(i, j)[k] * (1 - c) + rightImg.at<Vec3b>(i, j - leftOrigArea)[k] * c;

I think, it s problem with coefficient "c" datatype. if i use transform to "(float)", code works.