提交 4aee2e30 编写于 作者: V Vadim Pisarevsky

fixed incorrect assert in RGB2Lab_b constructor

上级 3843e43f
...@@ -1260,8 +1260,8 @@ struct RGB2Lab_b ...@@ -1260,8 +1260,8 @@ struct RGB2Lab_b
coeffs[i*3+(blueIdx^2)] = cvRound(_coeffs[i*3]*scale[i]); coeffs[i*3+(blueIdx^2)] = cvRound(_coeffs[i*3]*scale[i]);
coeffs[i*3+1] = cvRound(_coeffs[i*3+1]*scale[i]); coeffs[i*3+1] = cvRound(_coeffs[i*3+1]*scale[i]);
coeffs[i*3+blueIdx] = cvRound(_coeffs[i*3+2]*scale[i]); coeffs[i*3+blueIdx] = cvRound(_coeffs[i*3+2]*scale[i]);
CV_Assert( coeffs[i] >= 0 && coeffs[i+3] >= 0 && coeffs[i+6] >= 0 && CV_Assert( coeffs[i] >= 0 && coeffs[i*3+1] >= 0 && coeffs[i*3+2] >= 0 &&
coeffs[i] + coeffs[i+1] + coeffs[i+2] < 2*(1 << lab_shift) ); coeffs[i*3] + coeffs[i*3+1] + coeffs[i*3+2] < 2*(1 << lab_shift) );
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册